[Zope-Checkins] CVS: Zope/lib/python/Products/PluginIndexes/TextIndex/Splitter/UnicodeSplitter/src - UnicodeSplitter.c:1.13.4.3

Andreas Jung andreas@digicool.com
Thu, 24 Jan 2002 15:08:12 -0500


Update of /cvs-repository/Zope/lib/python/Products/PluginIndexes/TextIndex/Splitter/UnicodeSplitter/src
In directory cvs.zope.org:/tmp/cvs-serv19904/src

Modified Files:
      Tag: Zope-2_5-branch
	UnicodeSplitter.c 
Log Message:
fixed refcounting bug causing splitter to leak


=== Zope/lib/python/Products/PluginIndexes/TextIndex/Splitter/UnicodeSplitter/src/UnicodeSplitter.c 1.13.4.2 => 1.13.4.3 ===
     PyObject *value;
 
-    if (PyUnicode_GetSize(word)==1 && ! self->allow_single_chars)
+    if (PyUnicode_GetSize(word)==1 && ! self->allow_single_chars) {
+        Py_INCREF(Py_None);
         return Py_None;
+    }
 
     if (self->synstop) {
         value = PyDict_GetItem(self->synstop,word);