diff --git a/cogl/cogl/cogl-magazine-private.h b/cogl/cogl/cogl-magazine-private.h index b5cc95c10..507f751d9 100644 --- a/cogl/cogl/cogl-magazine-private.h +++ b/cogl/cogl/cogl-magazine-private.h @@ -73,6 +73,3 @@ _cogl_magazine_chunk_free (CoglMagazine *magazine, void *data) chunk->next = magazine->head; magazine->head = chunk; } - -void -_cogl_magazine_free (CoglMagazine *magazine); diff --git a/cogl/cogl/cogl-magazine.c b/cogl/cogl/cogl-magazine.c index c15583384..2e444598f 100644 --- a/cogl/cogl/cogl-magazine.c +++ b/cogl/cogl/cogl-magazine.c @@ -73,10 +73,3 @@ _cogl_magazine_new (size_t chunk_size, int initial_chunk_count) return magazine; } - -void -_cogl_magazine_free (CoglMagazine *magazine) -{ - _cogl_memory_stack_free (magazine->stack); - g_free (magazine); -} diff --git a/cogl/cogl/cogl-memory-stack-private.h b/cogl/cogl/cogl-memory-stack-private.h index fd6375b38..9f20ead96 100644 --- a/cogl/cogl/cogl-memory-stack-private.h +++ b/cogl/cogl/cogl-memory-stack-private.h @@ -39,6 +39,3 @@ _cogl_memory_stack_new (size_t initial_size_bytes); void * _cogl_memory_stack_alloc (CoglMemoryStack *stack, size_t bytes); - -void -_cogl_memory_stack_free (CoglMemoryStack *stack); diff --git a/cogl/cogl/cogl-memory-stack.c b/cogl/cogl/cogl-memory-stack.c index a7e29710b..042e2d519 100644 --- a/cogl/cogl/cogl-memory-stack.c +++ b/cogl/cogl/cogl-memory-stack.c @@ -161,25 +161,3 @@ _cogl_memory_stack_alloc (CoglMemoryStack *stack, size_t bytes) return sub_stack->data; } - -static void -_cogl_memory_sub_stack_free (CoglMemorySubStack *sub_stack) -{ - g_free (sub_stack->data); - g_free (sub_stack); -} - -void -_cogl_memory_stack_free (CoglMemoryStack *stack) -{ - - while (!_cogl_list_empty (&stack->sub_stacks)) - { - CoglMemorySubStack *sub_stack = - _cogl_container_of (stack->sub_stacks.next, CoglMemorySubStack, link); - _cogl_list_remove (&sub_stack->link); - _cogl_memory_sub_stack_free (sub_stack); - } - - g_free (stack); -}