Mercurial > cpython-lru_cache-weakref
diff Objects/unicodeobject.c @ 63460:765bfd8ec968
Revert r83395, it introduces test failures and is not necessary anyway since we now have to nul-terminate the string anyway.
| author | Georg Brandl <georg@python.org> |
|---|---|
| date | Sun, 01 Aug 2010 20:51:02 +0000 |
| parents | 66cb15c62db4 |
| children | a3853bfa2518 |
line wrap: on
line diff
--- a/Objects/unicodeobject.c Sun Aug 01 20:08:46 2010 +0000 +++ b/Objects/unicodeobject.c Sun Aug 01 20:51:02 2010 +0000 @@ -3734,7 +3734,7 @@ ch2 = *s++; size--; - if (ch2 >= 0xDC00 && ch2 <= 0xDFFF && size) { + if (ch2 >= 0xDC00 && ch2 <= 0xDFFF) { ucs = (((ch & 0x03FF) << 10) | (ch2 & 0x03FF)) + 0x00010000; *p++ = '\\'; *p++ = 'U'; @@ -3976,7 +3976,7 @@ ch2 = *s++; size--; - if (ch2 >= 0xDC00 && ch2 <= 0xDFFF && size) { + if (ch2 >= 0xDC00 && ch2 <= 0xDFFF) { ucs = (((ch & 0x03FF) << 10) | (ch2 & 0x03FF)) + 0x00010000; *p++ = '\\'; *p++ = 'U';
