diff options
author | Tim Janik <timj@gtk.org> | 1998-11-24 12:18:22 +0000 |
---|---|---|
committer | Tim Janik <timj@src.gnome.org> | 1998-11-24 12:18:22 +0000 |
commit | 9c1692c2604bf147d2b08877d8cebb1f077658e0 (patch) | |
tree | fc6f6f3a2e46a638f65e448d71eff427716c2808 /gstring.c | |
parent | eabb208b306f159264ed14d0362b56b7749a70e2 (diff) | |
download | glib-9c1692c2604bf147d2b08877d8cebb1f077658e0.tar.gz |
removed the GListAllocator type and its g_*_allocator_*() function
Tue Nov 24 09:40:00 1998 Tim Janik <timj@gtk.org>
* glib.h: removed the GListAllocator type and its g_*_allocator_*()
function variants (which weren't working anyways) in favour of a
generic GAllocator type. new functions:
g_allocator_new, g_allocator_free, g_slist_push_allocator,
g_slist_pop_allocator, g_list_push_allocator, g_list_pop_allocator,
g_node_push_allocator and g_node_pop_allocator.
* gstring.c: removed bogus slist allocator code.
* gtree.c: maintain own list of free tree nodes and don't waste
GSLists for that, removed bogus slist allocator code.
* glist.c: use GAllocators for node allocation.
* gslist.c: use GAllocators for node allocation.
* gnode.c: use GAllocators for node allocation.
* gdataset.c: cleanups wrt automatic initialization.
Diffstat (limited to 'gstring.c')
-rw-r--r-- | gstring.c | 7 |
1 files changed, 0 insertions, 7 deletions
@@ -106,14 +106,10 @@ g_string_chunk_free (GStringChunk *fchunk) if (chunk->storage_list) { - GListAllocator *tmp_allocator = g_slist_set_allocator (NULL); - for (tmp_list = chunk->storage_list; tmp_list; tmp_list = tmp_list->next) g_free (tmp_list->data); g_slist_free (chunk->storage_list); - - g_slist_set_allocator (tmp_allocator); } if (chunk->const_table) @@ -134,7 +130,6 @@ g_string_chunk_insert (GStringChunk *fchunk, if ((chunk->storage_next + len + 1) > chunk->this_size) { - GListAllocator *tmp_allocator = g_slist_set_allocator (NULL); gint new_size = chunk->default_size; while (new_size < len+1) @@ -145,8 +140,6 @@ g_string_chunk_insert (GStringChunk *fchunk, chunk->this_size = new_size; chunk->storage_next = 0; - - g_slist_set_allocator (tmp_allocator); } pos = ((char*)chunk->storage_list->data) + chunk->storage_next; |