From: David Malcolm Date: Wed, 19 Nov 2014 19:11:37 +0000 (+0000) Subject: PR jit/63854: Fix memory leak of reginfo.c: valid_mode_changes_obstack X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=a4fe9e9923db7931411e3bbf86892245f3bfb4e2;p=gcc.git PR jit/63854: Fix memory leak of reginfo.c: valid_mode_changes_obstack gcc/ChangeLog: PR jit/63854 * reginfo.c (finish_subregs_of_mode): Replace obstack_finish with obstack_free when cleaning up valid_mode_changes_obstack. From-SVN: r217792 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 90e86f6de00..e280fc2b97d 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,9 @@ +2014-11-19 David Malcolm + + PR jit/63854 + * reginfo.c (finish_subregs_of_mode): Replace obstack_finish with + obstack_free when cleaning up valid_mode_changes_obstack. + 2014-11-19 David Malcolm PR jit/63854 diff --git a/gcc/reginfo.c b/gcc/reginfo.c index efe23cdc41f..c2daf2216fa 100644 --- a/gcc/reginfo.c +++ b/gcc/reginfo.c @@ -1343,7 +1343,7 @@ void finish_subregs_of_mode (void) { XDELETEVEC (valid_mode_changes); - obstack_finish (&valid_mode_changes_obstack); + obstack_free (&valid_mode_changes_obstack, NULL); } /* Free all data attached to the structure. This isn't a destructor because