From: Michael Snyder Date: Thu, 3 Mar 2011 01:15:45 +0000 (+0000) Subject: 2011-03-02 Michael Snyder X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=240f9570d5fd873479a18e00be49519cd3aedbfc;p=binutils-gdb.git 2011-03-02 Michael Snyder * maint.c (maintenance_do_deprecate): No need to check for NULL. --- diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 0c61e0cd32c..ee6802c9d58 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,5 +1,7 @@ 2011-03-02 Michael Snyder + * maint.c (maintenance_do_deprecate): No need to check for NULL. + * cli/cli-script.c (script_from_file): Add break for lint. * mdebugread.c (parse_partial_symbols): Fix indent. diff --git a/gdb/maint.c b/gdb/maint.c index 101c2de6178..ca9b3cca643 100644 --- a/gdb/maint.c +++ b/gdb/maint.c @@ -644,9 +644,7 @@ maintenance_do_deprecate (char *text, int deprecate) cmd->flags |= MALLOCED_REPLACEMENT; return; } - /* If we get here, don't leak! */ - if (replacement != NULL) - xfree (replacement); + xfree (replacement); } /* Maintenance set/show framework. */