2008-05-04 Jan Kratochvil * symfile.c (reread_symbols): Reload EXEC_BFD on its change. =================================================================== RCS file: /cvs/src/src/gdb/symfile.c,v retrieving revision 1.201 retrieving revision 1.202 diff -u -r1.201 -r1.202 --- src/gdb/symfile.c 2008/05/04 03:45:42 1.201 +++ src/gdb/symfile.c 2008/05/04 14:34:06 1.202 @@ -2331,6 +2331,14 @@ /* We need to do this whenever any symbols go away. */ make_cleanup (clear_symtab_users_cleanup, 0 /*ignore*/); + if (exec_bfd != NULL && strcmp (bfd_get_filename (objfile->obfd), + bfd_get_filename (exec_bfd)) == 0) + { + /* Reload EXEC_BFD without asking anything. */ + + exec_file_attach (bfd_get_filename (objfile->obfd), 0); + } + /* Clean up any state BFD has sitting around. We don't need to close the descriptor but BFD lacks a way of closing the BFD without closing the descriptor. */