From: Tim Peters Date: Sun, 31 Mar 2002 02:59:48 +0000 (+0000) Subject: Add one more assert that indirectly interlocking conditions are consistent X-Git-Tag: v2.3c1~6224 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=57b17ad6aeb821262aef41ffd31d1302f18e79c5;p=python Add one more assert that indirectly interlocking conditions are consistent with each other. --- diff --git a/Objects/obmalloc.c b/Objects/obmalloc.c index 019aa5bf21..cf2b477d1c 100644 --- a/Objects/obmalloc.c +++ b/Objects/obmalloc.c @@ -686,6 +686,7 @@ _PyMalloc_Free(void *p) * was full and is in no list -- it's not in the freeblocks * list in any case). */ + assert(pool->ref.count > 0); /* else it was empty */ *(block **)p = lastfree = pool->freeblock; pool->freeblock = (block *)p; if (lastfree) {