projects
/
fio.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
adf5709
)
smalloc: remember to account for sizeof block header
author
Jens Axboe
<jens.axboe@oracle.com>
Wed, 16 Apr 2008 17:47:21 +0000
(19:47 +0200)
committer
Jens Axboe
<jens.axboe@oracle.com>
Wed, 16 Apr 2008 17:47:21 +0000
(19:47 +0200)
Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
smalloc.c
patch
|
blob
|
blame
|
history
diff --git
a/smalloc.c
b/smalloc.c
index 28f82633b23661c9e49f80612ac2c6d550c4fa8e..8d1193ab9f57e32aa5bb29431a760162116b2ca8 100644
(file)
--- a/
smalloc.c
+++ b/
smalloc.c
@@
-231,6
+231,7
@@
static int add_pool(struct pool *pool, unsigned int alloc_size)
if (fd < 0)
goto out_close;
if (fd < 0)
goto out_close;
+ alloc_size += sizeof(*hdr);
if (alloc_size > smalloc_pool_size)
pool->size = alloc_size;
else
if (alloc_size > smalloc_pool_size)
pool->size = alloc_size;
else