mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-08-21 16:38:54 +02:00
Fix problem where if g_mem_chunk_reset() is called on an alloc-only
Fri Mar 22 17:59:27 2002 Owen Taylor <otaylor@redhat.com> * glib/gmem.c (g_mem_chunk_reset): Fix problem where if g_mem_chunk_reset() is called on an alloc-only memchunk, then a useles GTree was created.
This commit is contained in:
@@ -1021,8 +1021,10 @@ g_mem_chunk_reset (GMemChunk *mem_chunk)
|
||||
mem_chunk->free_atoms = NULL;
|
||||
|
||||
if (mem_chunk->mem_tree)
|
||||
g_tree_destroy (mem_chunk->mem_tree);
|
||||
mem_chunk->mem_tree = g_tree_new ((GCompareFunc) g_mem_chunk_area_compare);
|
||||
{
|
||||
g_tree_destroy (mem_chunk->mem_tree);
|
||||
mem_chunk->mem_tree = g_tree_new ((GCompareFunc) g_mem_chunk_area_compare);
|
||||
}
|
||||
|
||||
LEAVE_MEM_CHUNK_ROUTINE ();
|
||||
}
|
||||
|
Reference in New Issue
Block a user