summary |
shortlog |
log |
commit | commitdiff |
tree
raw |
patch |
inline | side by side (from parent 1:
95e5645)
This can happen if we pass sfree() memory not allocated by smalloc.
Ignore it and log an error instead of triggering an assert().
Signed-off-by: Jens Axboe <axboe@fb.com>
- assert(pool);
- sfree_pool(pool, ptr);
+ if (pool) {
+ sfree_pool(pool, ptr);
+ return;
+ }
+
+ log_err("smalloc: ptr %p not from smalloc pool\n", ptr);
}
static void *__smalloc_pool(struct pool *pool, size_t size)
}
static void *__smalloc_pool(struct pool *pool, size_t size)