diff options
author | Tobias Burnus <burnus@net-b.de> | 2012-11-12 12:00:58 +0100 |
---|---|---|
committer | Tobias Burnus <burnus@gcc.gnu.org> | 2012-11-12 12:00:58 +0100 |
commit | 3b4adfb357d82d4a83852a02febc008249579c8e (patch) | |
tree | c28159e69dee0727a02304cb3889277dc61bfe5c | |
parent | f27f1e98957a6b98c24a86a01e995e9d638c3258 (diff) | |
download | gcc-3b4adfb357d82d4a83852a02febc008249579c8e.zip gcc-3b4adfb357d82d4a83852a02febc008249579c8e.tar.gz gcc-3b4adfb357d82d4a83852a02febc008249579c8e.tar.bz2 |
diagnostic.c (diagnostic_append_note): Also call va_end when inhibit_notes_p is true.
2012-11-12 Tobias Burnus <burnus@net-b.de>
* diagnostic.c (diagnostic_append_note): Also call va_end when
inhibit_notes_p is true.
From-SVN: r193428
-rw-r--r-- | gcc/ChangeLog | 5 | ||||
-rw-r--r-- | gcc/diagnostic.c | 5 |
2 files changed, 9 insertions, 1 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 9a82d73..d815477 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,8 @@ +2012-11-12 Tobias Burnus <burnus@net-b.de> + + * diagnostic.c (diagnostic_append_note): Also call va_end when + inhibit_notes_p is true. + 2012-11-12 Bin Cheng <bin.cheng@arm.com> * gcse.c (struct bb_data): Add new fields, old_pressure, live_in diff --git a/gcc/diagnostic.c b/gcc/diagnostic.c index ff210dc..4d9b007 100644 --- a/gcc/diagnostic.c +++ b/gcc/diagnostic.c @@ -833,7 +833,10 @@ diagnostic_append_note (diagnostic_context *context, va_start (ap, gmsgid); diagnostic_set_info (&diagnostic, gmsgid, &ap, location, DK_NOTE); if (context->inhibit_notes_p) - return; + { + va_end (ap); + return; + } pp_set_prefix (context->printer, diagnostic_build_prefix (context, &diagnostic)); pp_newline (context->printer); |