@@ -173,7 +173,7 @@ int free_s(void *p, int size) {
while (pool && pool->cache != cache)
pool = pool->next_pool;
- if (!pool)
+ if (!pool && size)
panic("WARNING: free_s: object is not in any mempool\n");
}
@@ -53,7 +53,7 @@ static int number(char *buf, long x, int base, int flags, int width) {
memset(t, 0, PTRSIZE * 2);
- if (!(flags & UNSIGNED) && nr < 0) {
+ if (!(flags & UNSIGNED) && x < 0) {
nr = -x;
neg = 1;