* breakpoint.c (bpstat_check_breakpoint_conditions): Use

value_mark and value_free_to_mark.
	* objfiles.c (free_objfile): Call objfile_free_data before
	freeing the BFD.
This commit is contained in:
Daniel Jacobowitz
2009-03-11 20:26:02 +00:00
parent 09e8c3bf89
commit c5bc3a77a2
3 changed files with 18 additions and 2 deletions

View File

@ -422,6 +422,9 @@ free_objfile (struct objfile *objfile)
(*objfile->sf->sym_finish) (objfile);
}
/* Discard any data modules have associated with the objfile. */
objfile_free_data (objfile);
/* We always close the bfd, unless the OBJF_KEEPBFD flag is set. */
if (objfile->obfd != NULL && !(objfile->flags & OBJF_KEEPBFD))
@ -476,7 +479,6 @@ free_objfile (struct objfile *objfile)
/* The last thing we do is free the objfile struct itself. */
objfile_free_data (objfile);
if (objfile->name != NULL)
{
xfree (objfile->name);