diff options
| author | Anand V. Avati <avati@amp.gluster.com> | 2009-04-22 12:55:47 +0530 | 
|---|---|---|
| committer | Anand V. Avati <avati@amp.gluster.com> | 2009-04-22 13:07:40 +0530 | 
| commit | 7eb63e30f22f7a9d785f6620be22d2b3aab77ada (patch) | |
| tree | bcc5eb1db64f7f17f962371ab097993daaba10ad /libglusterfs | |
| parent | 4877476fa1a591c51f4b3ee76082766f38a33b23 (diff) | |
iobuf_pool->arenas_cnt should be incremented in iobuf_arena_alloc, and not iobuf_pool_add_arena (to avoid counting of unpruned arenas)
Signed-off-by: Anand V. Avati <avati@amp.gluster.com>
Diffstat (limited to 'libglusterfs')
| -rw-r--r-- | libglusterfs/src/iobuf.c | 3 | 
1 files changed, 2 insertions, 1 deletions
diff --git a/libglusterfs/src/iobuf.c b/libglusterfs/src/iobuf.c index 7cbc1702e7e..6d6fca13388 100644 --- a/libglusterfs/src/iobuf.c +++ b/libglusterfs/src/iobuf.c @@ -135,6 +135,8 @@ __iobuf_arena_alloc (struct iobuf_pool *iobuf_pool)          if (!iobuf_arena->iobufs)                  goto err; +        iobuf_pool->arena_cnt++; +          return iobuf_arena;  err: @@ -173,7 +175,6 @@ __iobuf_pool_add_arena (struct iobuf_pool *iobuf_pool)                  return NULL;          list_add_tail (&iobuf_arena->list, &iobuf_pool->arenas.list); -        iobuf_pool->arena_cnt++;          return iobuf_arena;  }  | 
