From: Andrew M. Kuchling Date: Tue, 3 Oct 2006 19:18:33 +0000 (+0000) Subject: [Partial backport of r50777 | neal.norwitz] X-Git-Tag: v2.4.4c1~63 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=a2040255ca62d0250920fa744ac813e396ee0680;p=thirdparty%2FPython%2Fcpython.git [Partial backport of r50777 | neal.norwitz] Handle more mem alloc issues found with failmalloc [The other half of this patch affected Python/symtable.c, and wasn't relevant for the 2.4 branch. --amk] --- diff --git a/Python/future.c b/Python/future.c index 20d8dd290924..38edc87501cf 100644 --- a/Python/future.c +++ b/Python/future.c @@ -246,8 +246,10 @@ PyNode_Future(node *n, const char *filename) PyFutureFeatures *ff; ff = (PyFutureFeatures *)PyMem_Malloc(sizeof(PyFutureFeatures)); - if (ff == NULL) + if (ff == NULL) { + PyErr_NoMemory(); return NULL; + } ff->ff_found_docstring = 0; ff->ff_last_lineno = -1; ff->ff_features = 0;