]> granicus.if.org Git - python/commit
bpo-37732: Fix GCC warning in _PyObject_Malloc() (GH-15333) (GH-15342)
authorVictor Stinner <vstinner@redhat.com>
Tue, 20 Aug 2019 12:44:32 +0000 (13:44 +0100)
committerGitHub <noreply@github.com>
Tue, 20 Aug 2019 12:44:32 +0000 (13:44 +0100)
commit30e5aff5fb0e3841107ddd4539a1f5b8521c80fb
tree463641e4d6ba2e703ee29483fda11920aa01a604
parent1271ee8187df31debda7c556882a51ec356ca534
bpo-37732: Fix GCC warning in _PyObject_Malloc() (GH-15333) (GH-15342)

pymalloc_alloc() now returns directly the pointer, return NULL on
memory allocation error.

allocate_from_new_pool() already uses NULL as marker for "allocation
failed".

(cherry picked from commit 18f8dcfa10d8a858b152d12a9ad8fa83b7e967f0)
Objects/obmalloc.c