commit | 7c460740ede2b14d5b4792e6c2bccc6d53cf0206 | [log] [tgz] |
---|---|---|
author | Neal Norwitz <nnorwitz@gmail.com> | Sun Dec 18 08:02:38 2005 +0000 |
committer | Neal Norwitz <nnorwitz@gmail.com> | Sun Dec 18 08:02:38 2005 +0000 |
tree | 0c56bfe2cc774a29c29681a1c66a27af0fe4d265 | |
parent | 51abbc7b4affeeedb8faf1adee8195be9ad8195f [diff] |
Check return result for error
diff --git a/Objects/bufferobject.c b/Objects/bufferobject.c index da8d9fc..56748e6 100644 --- a/Objects/bufferobject.c +++ b/Objects/bufferobject.c
@@ -356,6 +356,8 @@ return NULL; ob = PyString_FromStringAndSize(NULL, size + count); + if ( ob == NULL ) + return NULL; p = PyString_AS_STRING(ob); memcpy(p, ptr1, size); memcpy(p + size, ptr2, count);