commit | bea424af98468a7fc5c505c949218e22862d2b40 | [log] [tgz] |
---|---|---|
author | Benjamin Peterson <benjamin@python.org> | Sat Apr 03 00:57:33 2010 +0000 |
committer | Benjamin Peterson <benjamin@python.org> | Sat Apr 03 00:57:33 2010 +0000 |
tree | 6990df25667157e2a0d4f50f5e2ac0887810f046 | |
parent | 3928276e6442f52b0a2717df8d8441dbe03ccd53 [diff] [blame] |
more _PyString_Resize error checking
diff --git a/Python/marshal.c b/Python/marshal.c index c7015d2..9e4a692 100644 --- a/Python/marshal.c +++ b/Python/marshal.c
@@ -1237,7 +1237,8 @@ "too much marshall data for a string"); return NULL; } - _PyString_Resize(&wf.str, (Py_ssize_t)(wf.ptr - base)); + if (_PyString_Resize(&wf.str, (Py_ssize_t)(wf.ptr - base))) + return NULL; } if (wf.error != WFERR_OK) { Py_XDECREF(wf.str);