ALT Linux repos
Group :: Development/Python
RPM: python
Main Changelog Spec Patches Sources Download Gear Bugs and FR Repocop
Patch: python-2.5-CVE-2008-1721.patch
Download
Download
Index: Objects/stringobject.c
===================================================================
--- Objects/stringobject.c (revision 62261)
+++ Objects/stringobject.c (revision 62262)
@@ -54,6 +54,11 @@
{
register PyStringObject *op;
assert(size >= 0);
+ if (size < 0) {
+ PyErr_SetString(PyExc_SystemError,
+ "Negative size passed to PyString_FromStringAndSize");
+ return NULL;
+ }
if (size == 0 && (op = nullstring) != NULL) {
#ifdef COUNT_ALLOCS
null_strings++;