commit | 2ad8c56e6c77f5eb04a9004f525b59ee717a8f3d | [log] [tgz] |
---|---|---|
author | Tim Peters <tim.peters@gmail.com> | Thu Feb 16 20:19:46 2006 +0000 |
committer | Tim Peters <tim.peters@gmail.com> | Thu Feb 16 20:19:46 2006 +0000 |
tree | 1c1b387c687d444bfd0e5da3102fa8eb90b125d6 | |
parent | 02cbdd3461b07bde5f3c304c1c316191c0a73c52 [diff] |
struct_pack(): Repair new assert-fail crash in debug-build test_struct on a box where plain "char" is signed.
diff --git a/Modules/structmodule.c b/Modules/structmodule.c index 2fa6e90..4713c0c 100644 --- a/Modules/structmodule.c +++ b/Modules/structmodule.c
@@ -1134,7 +1134,7 @@ if (n > 255) n = 255; /* store the length byte */ - *res++ = Py_SAFE_DOWNCAST(n, Py_ssize_t, char); + *res++ = Py_SAFE_DOWNCAST(n, Py_ssize_t, unsigned char); res += num; break; }