瀏覽代碼

Perform req_padding() before searching for a fixed list.

Ioannis Koutras 13 年之前
父節點
當前提交
d4e695665a
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      custom_malloc.c

+ 1 - 1
custom_malloc.c

@@ -20,7 +20,7 @@ void * custom_malloc(heap_t* heap, size_t size) {
     posix_lock(heap);
 #endif /* HAVE_LOCKS */
 
-    fixed_list_id = map_size_to_list(heap, size);
+    fixed_list_id = map_size_to_list(heap, req_padding(size));
 
     // If a fixed list is found, do a first fit
     if(fixed_list_id != -1) {