Staging
v0.5.1
https://github.com/python/cpython
Revision d9ddf59d28dd17f4a3aecf5e1964ae849805cf48 authored by Guido van Rossum on 11 October 2002, 00:47:20 UTC, committed by Guido van Rossum on 11 October 2002, 00:47:20 UTC
Fix a nasty endcase reported by Armin Rigo in SF bug 618623:
'%2147483647d' % -123 segfaults.  This was because an integer overflow
in a comparison caused the string resize to be skipped.  After fixing
the overflow, this could call _PyString_Resize() with a negative size,
so I (1) test for that and raise MemoryError instead; (2) also added a
test for negative newsize to _PyString_Resize(), raising SystemError
as for all bad arguments.

An identical bug existed in unicodeobject.c, of course.
1 parent ebc6a65
History
Tip revision: d9ddf59d28dd17f4a3aecf5e1964ae849805cf48 authored by Guido van Rossum on 11 October 2002, 00:47:20 UTC
Backport stringobject.c 2.194 and unicodeobject.c 2.172:
Tip revision: d9ddf59
File Mode Size
RPM
ACKS -rw-r--r-- 8.3 KB
AIX-NOTES -rw-r--r-- 7.3 KB
BeOS-NOTES -rw-r--r-- 1.4 KB
BeOS-setup.py -rw-r--r-- 24.6 KB
HISTORY -rw-r--r-- 305.2 KB
HPUX-NOTES -rw-r--r-- 1.0 KB
NEWS -rw-r--r-- 143.1 KB
PURIFY.README -rw-r--r-- 3.6 KB
Porting -rw-r--r-- 1.9 KB
README -rw-r--r-- 1.2 KB
RFD -rw-r--r-- 3.9 KB
cheatsheet -rw-r--r-- 99.9 KB
find_recursionlimit.py -rw-r--r-- 2.2 KB
gdbinit -rw-r--r-- 898 bytes
indent.pro -rw-r--r-- 66 bytes
python-mode.el -rw-r--r-- 120.7 KB
python.man -rw-r--r-- 11.4 KB
setuid-prog.c -rw-r--r-- 5.3 KB
vgrindefs -rw-r--r-- 505 bytes

README

back to top