diff options
author | Keith Seitz <keiths@redhat.com> | 2012-05-31 18:44:50 +0000 |
---|---|---|
committer | Keith Seitz <keiths@redhat.com> | 2012-05-31 18:44:50 +0000 |
commit | 71bdabee218e22fa592ab679a2d1ee044e0f6e2c (patch) | |
tree | 0026ab4808725db7b4858275ac13e940c7a5ad65 /gdb/linespec.c | |
parent | 2d376810dc04fbbcfcd9af8f3a2692f47746f980 (diff) | |
download | gdb-71bdabee218e22fa592ab679a2d1ee044e0f6e2c.zip gdb-71bdabee218e22fa592ab679a2d1ee044e0f6e2c.tar.gz gdb-71bdabee218e22fa592ab679a2d1ee044e0f6e2c.tar.bz2 |
* linespec.c (decode_objc): Add cleanup to free
INFO.FILE_SYMTABS.
(find_linespec_symbols): Add cleanup to free CLASSES.
* symfile.c (find_separate_debug_file_by_debuglink): Add
cleanup to free DEBUGLINK.
* ui-out.c (clear_header_list): No need to check if
HEADER_NEXT.COLHDR is NULL.
Free HEADER_NEXT.COL_NAME.
Diffstat (limited to 'gdb/linespec.c')
-rw-r--r-- | gdb/linespec.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/gdb/linespec.c b/gdb/linespec.c index ee91adf..e678dfa 100644 --- a/gdb/linespec.c +++ b/gdb/linespec.c @@ -2409,6 +2409,7 @@ decode_objc (struct linespec_state *self, linespec_p ls, char **argptr) info.state = self; info.file_symtabs = NULL; VEC_safe_push (symtab_p, info.file_symtabs, NULL); + make_cleanup (VEC_cleanup (symtab_p), &info.file_symtabs); info.result.symbols = NULL; info.result.minimal_symbols = NULL; values.nelts = 0; @@ -2949,6 +2950,7 @@ find_linespec_symbols (struct linespec_state *state, /* Find a list of classes named KLASS. */ classes = lookup_prefix_sym (state, file_symtabs, klass); + make_cleanup (VEC_cleanup (symbolp), &classes); if (!VEC_empty (symbolp, classes)) { /* Now locate a list of suitable methods named METHOD. */ |