From 8ef934c73f3baeaa582efb8de906b27a3854979c Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Mon, 26 Aug 2013 23:37:08 +0000 Subject: ghash/bli-listbase edits, rename BLI_ghash_pop -> BLI_ghash_popkey (since it takes a key as an arg and isnt popping any element from the hash as you might expect). add BLI_pophead/tail, since getting the first element from a list and removing it is a common task. --- source/blender/gpu/intern/gpu_codegen.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'source/blender/gpu/intern/gpu_codegen.c') diff --git a/source/blender/gpu/intern/gpu_codegen.c b/source/blender/gpu/intern/gpu_codegen.c index e244c7cf57f..d7919125fee 100644 --- a/source/blender/gpu/intern/gpu_codegen.c +++ b/source/blender/gpu/intern/gpu_codegen.c @@ -1039,9 +1039,7 @@ static void GPU_nodes_free(ListBase *nodes) { GPUNode *node; - while (nodes->first) { - node = nodes->first; - BLI_remlink(nodes, node); + while ((node = BLI_pophead(nodes))) { GPU_node_free(node); } } -- cgit v1.2.3