(*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))
/* The last thing we do is free the objfile struct itself. */
- objfile_free_data (objfile);
if (objfile->name != NULL)
{
xfree (objfile->name);
}
/* Relocate breakpoints as necessary, after things are relocated. */
- breakpoint_re_set ();
+ breakpoint_re_set_objfile (objfile);
}
\f
/* Many places in gdb want to test just to see if we have any partial