From b3fe43da1da44d7d89fefeb41b14e81238e51c23 Mon Sep 17 00:00:00 2001 From: Moinak Ghosh Date: Thu, 31 May 2012 18:12:32 +0530 Subject: [PATCH] Fix dynamic slab insertion. --- allocator.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/allocator.c b/allocator.c index 228578a..9b301cf 100644 --- a/allocator.c +++ b/allocator.c @@ -358,8 +358,8 @@ slab_cache_add(size_t size) pthread_mutex_init(&(slab->slab_lock), NULL); pthread_mutex_lock(&(slabheads[sindx].slab_lock)); - slabheads[sindx].next = slab; slab->next = slabheads[sindx].next; + slabheads[sindx].next = slab; pthread_mutex_unlock(&(slabheads[sindx].slab_lock)); } return (1);