diff options
author | Guido van Rossum <guido@python.org> | 2000-04-06 18:18:10 (GMT) |
---|---|---|
committer | Guido van Rossum <guido@python.org> | 2000-04-06 18:18:10 (GMT) |
commit | ba47704943137318229ad9a4bba6a93aa0ba1d29 (patch) | |
tree | c8018e8f07be7fbfe585e70e57f3b530166ec316 /Objects | |
parent | 69ca950d1ff6a5344f1680846af85facfdf7bc14 (diff) | |
download | cpython-ba47704943137318229ad9a4bba6a93aa0ba1d29.zip cpython-ba47704943137318229ad9a4bba6a93aa0ba1d29.tar.gz cpython-ba47704943137318229ad9a4bba6a93aa0ba1d29.tar.bz2 |
Conrad Huang points out that "if (0 < ch < 256)", while legal C,
doesn't mean what the Python programmer thought...
Diffstat (limited to 'Objects')
-rw-r--r-- | Objects/unicodeobject.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Objects/unicodeobject.c b/Objects/unicodeobject.c index b876f34..e4bbcff 100644 --- a/Objects/unicodeobject.c +++ b/Objects/unicodeobject.c @@ -1958,7 +1958,7 @@ int PyUnicode_EncodeDecimal(Py_UNICODE *s, *output++ = '0' + decimal; continue; } - if (0 < ch < 256) { + if (0 < ch && ch < 256) { *output++ = (char) ch; continue; } |