aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--gdb/ChangeLog2
-rw-r--r--gdb/source.c1
2 files changed, 3 insertions, 0 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog
index bea69db..8ce75e6 100644
--- a/gdb/ChangeLog
+++ b/gdb/ChangeLog
@@ -1,5 +1,7 @@
2007-06-28 Michael Snyder <msnyder@access-company.com>
+ * source.c (unset_substitute_path_command): Plug leak (Coverity).
+
* cli/cli-script.c (build_command_line): Add null pointer guard
(Coverity).
diff --git a/gdb/source.c b/gdb/source.c
index a142b32..1067e62 100644
--- a/gdb/source.c
+++ b/gdb/source.c
@@ -1852,6 +1852,7 @@ unset_substitute_path_command (char *args, int from_tty)
/* This function takes either 0 or 1 argument. */
+ make_cleanup_freeargv (argv);
if (argv != NULL && argv[0] != NULL && argv[1] != NULL)
error (_("Incorrect usage, too many arguments in command"));