Lines Matching refs:NULL
43 static malloc_mem_chunk_t *malloc_free_list = NULL;
44 static malloc_mem_chunk_t *malloc_free_list_end = NULL; // 空闲链表的末尾结点
72 if (malloc_free_list == NULL) in malloc_query_free_chunk_bf()
74 return NULL; in malloc_query_free_chunk_bf()
77 malloc_mem_chunk_t *best = NULL; in malloc_query_free_chunk_bf()
79 while (ptr != NULL) in malloc_query_free_chunk_bf()
90 if (best == NULL) in malloc_query_free_chunk_bf()
109 if (malloc_free_list == NULL) in malloc_query_free_chunk_ff()
110 return NULL; in malloc_query_free_chunk_ff()
122 return NULL; in malloc_query_free_chunk_ff()
161 new_ck->prev = NULL; in malloc_enlarge()
162 new_ck->next = NULL; in malloc_enlarge()
176 if (malloc_free_list == NULL) in malloc_merge_free_chunk()
179 while (ptr != NULL) in malloc_merge_free_chunk()
188 if (ptr->next == NULL) in malloc_merge_free_chunk()
206 if (malloc_free_list == NULL) // 空闲链表为空 in malloc_insert_free_list()
210 ck->prev = ck->next = NULL; in malloc_insert_free_list()
217 while (ptr != NULL) in malloc_insert_free_list()
221 if (ptr->next == NULL) // 当前是最后一个项 in malloc_insert_free_list()
224 ck->next = NULL; in malloc_insert_free_list()
241 if (ptr->prev == NULL) // 是第一个项 in malloc_insert_free_list()
244 ck->prev = NULL; in malloc_insert_free_list()
283 if (ck == NULL) // 没有空闲块 in malloc()
310 if (ck == NULL) in malloc()
315 if (ck->prev == NULL) // 当前是链表的第一个块 in malloc()
322 if (ck->next != NULL) // 当前不是最后一个块 in malloc()
333 new_ck->prev = new_ck->next = NULL; in malloc()
351 if (malloc_free_list_end == NULL) in release_brk()