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
This commit is contained in:
David Malcolm 2014-11-19 19:11:37 +00:00 committed by David Malcolm
parent 0ef443cf01
commit a4fe9e9923
2 changed files with 7 additions and 1 deletions

View File

@ -1,3 +1,9 @@
2014-11-19 David Malcolm <dmalcolm@redhat.com>
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 <dmalcolm@redhat.com>
PR jit/63854

View File

@ -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