aboutsummaryrefslogtreecommitdiff
path: root/lib.h
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@evo.osdl.org>2005-08-11 15:14:53 -0700
committerLinus Torvalds <torvalds@evo.osdl.org>2005-08-11 15:14:53 -0700
commit71c2abb492618b099883dd2e625edace98bc9996 (patch)
treec967b1042e7447f4ad630c5c8f518583ccca5376 /lib.h
parentAdd 'undo_ptr_list_last()' helper function (diff)
downloadsparse-71c2abb492618b099883dd2e625edace98bc9996.tar.gz
sparse-71c2abb492618b099883dd2e625edace98bc9996.tar.bz2
sparse-71c2abb492618b099883dd2e625edace98bc9996.zip
Make delete_last_instruction() use the new undo_ptr_list_last() fn
Not only are we always going to replace the last instruction with something else, we can't afford to free the ptrlist, because the caller is usually walking over it in a loop.
Diffstat (limited to 'lib.h')
-rw-r--r--lib.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib.h b/lib.h
index 324a8a0..852f3af 100644
--- a/lib.h
+++ b/lib.h
@@ -122,7 +122,7 @@ static inline void free_instruction_list(struct instruction_list **head)
static inline struct instruction * delete_last_instruction(struct instruction_list **head)
{
- return delete_ptr_list_last((struct ptr_list **)head);
+ return undo_ptr_list_last((struct ptr_list **)head);
}
static inline struct basic_block * delete_last_basic_block(struct basic_block_list **head)