diff Objects/unicodeobject.c @ 48072:b71d76bf4506 2.5

#2242: utf7 decoding crashes on bogus input on some Windows/MSVC versions
author Antoine Pitrou <solipsis@pitrou.net>
date Fri, 25 Jul 2008 19:00:48 +0000
parents 42285d63755a
children 0aafd1ae5120
line wrap: on
line diff
--- a/Objects/unicodeobject.c	Wed Jul 16 11:04:17 2008 +0000
+++ b/Objects/unicodeobject.c	Fri Jul 25 19:00:48 2008 +0000
@@ -974,7 +974,7 @@
     while (s < e) {
         Py_UNICODE ch;
         restart:
-        ch = *s;
+        ch = (unsigned char) *s;
 
         if (inShift) {
             if ((ch == '-') || !B64CHAR(ch)) {