From: Guido van Rossum Date: Tue, 12 Aug 1997 14:54:54 +0000 (+0000) Subject: Fix mixup about PyErr_NoMemory() prototype. X-Git-Tag: v1.5a3~97 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=ea46e4d93cd52501461125ff52c3d4104fed68d0;p=thirdparty%2FPython%2Fcpython.git Fix mixup about PyErr_NoMemory() prototype. --- diff --git a/Objects/object.c b/Objects/object.c index 83829d26c263..6adc2be113b1 100644 --- a/Objects/object.c +++ b/Objects/object.c @@ -699,8 +699,10 @@ Py_Malloc(nbytes) p = malloc(nbytes); if (p != NULL) return p; - else - return PyErr_NoMemory(); + else { + PyErr_NoMemory(); + return NULL; + } } ANY * @@ -715,8 +717,10 @@ Py_Realloc(p, nbytes) p = realloc(p, nbytes); if (p != NULL) return p; - else - return PyErr_NoMemory(); + else { + PyErr_NoMemory(); + return NULL; + } } void