]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
Merged revisions 72844 via svnmerge from
authorMartin v. Löwis <martin@v.loewis.de>
Sat, 23 May 2009 10:44:10 +0000 (10:44 +0000)
committerMartin v. Löwis <martin@v.loewis.de>
Sat, 23 May 2009 10:44:10 +0000 (10:44 +0000)
svn+ssh://pythondev@svn.python.org/python/branches/py3k

........
  r72844 | martin.v.loewis | 2009-05-23 12:38:26 +0200 (Sa, 23 Mai 2009) | 2 lines

  Issue #6093: Fix off-by-one error in locale.strxfrm.
........

Misc/NEWS
Modules/_localemodule.c

index 668786fe4079f48e4ee0a7a3e478cb0e4b85fd16..2b40d6835b1ca3fceff97e0604c07034aea4b442 100644 (file)
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -160,6 +160,11 @@ Library
 - Issue #2703: SimpleXMLRPCDispatcher.__init__: Provide default values for
   new arguments introduced in 2.5.
 
+Extension Modules
+-----------------
+
+- Issue #6093: Fix off-by-one error in locale.strxfrm.
+
 Build
 -----
 
index 432df36973ddcb1cacce87a6a70c0548707c2afc..50378a72860a9b7a7baeaf93454338d7610c006b 100644 (file)
@@ -314,7 +314,7 @@ PyLocale_strxfrm(PyObject* self, PyObject* args)
             PyErr_NoMemory();
             goto exit;
         }
-        n2 = wcsxfrm(buf, s, n2);
+        n2 = wcsxfrm(buf, s, n2+1);
     }
     result = PyUnicode_FromWideChar(buf, n2);
  exit: