]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
Patch #1213831: Fix typo in unicodedata._getcode.
authorMartin v. Löwis <martin@v.loewis.de>
Sun, 18 Sep 2005 08:17:56 +0000 (08:17 +0000)
committerMartin v. Löwis <martin@v.loewis.de>
Sun, 18 Sep 2005 08:17:56 +0000 (08:17 +0000)
Will backport to Python 2.4.

Misc/NEWS
Modules/unicodedata.c

index fca9b552200537f3a91b4e06234774774de438c4..1ffa307782ae54408394fcb0746e91a892647c03 100644 (file)
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -143,6 +143,8 @@ Core and builtins
 Extension Modules
 -----------------
 
+- Patch #1213831: Fix typo in unicodedata._getcode.
+
 - Bug #1007046: os.startfile() did not accept unicode strings encoded in
   the file system encoding.
 
index 021bacf7b6a3f2baf806b3a796097537dd877b42..be966f096450a88fcba091bbb7952c2c050faa0b 100644 (file)
@@ -820,7 +820,7 @@ _getcode(const char* name, int namelen, Py_UCS4* code)
        pos += len;
        find_syllable(pos, &len, &T, TCount, 2);
        pos += len;
-       if (V != -1 && V != -1 && T != -1 && pos-name == namelen) {
+       if (L != -1 && V != -1 && T != -1 && pos-name == namelen) {
            *code = SBase + (L*VCount+V)*TCount + T;
            return 1;
        }