2007-08-10 Michael Snyder * solib-svr4.c (enable_break): Don't free tmp_pathname until after closing bfd. Index: solib-svr4.c =================================================================== RCS file: /cvs/src/src/gdb/solib-svr4.c,v retrieving revision 1.72 diff -p -r1.72 solib-svr4.c *** solib-svr4.c 8 Aug 2007 18:08:52 -0000 1.72 --- solib-svr4.c 10 Aug 2007 20:41:16 -0000 *************** enable_break (void) *** 1008,1014 **** tmp_fd = solib_open (buf, &tmp_pathname); if (tmp_fd >= 0) tmp_bfd = bfd_fopen (tmp_pathname, gnutarget, FOPEN_RB, tmp_fd); - xfree (tmp_pathname); if (tmp_bfd == NULL) goto bkpt_at_symbol; --- 1008,1013 ---- *************** enable_break (void) *** 1102,1107 **** --- 1101,1107 ---- /* For whatever reason we couldn't set a breakpoint in the dynamic linker. Warn and drop into the old code. */ bkpt_at_symbol: + xfree (tmp_pathname); warning (_("Unable to find dynamic linker breakpoint function.\n" "GDB will be unable to debug shared library initializers\n" "and track explicitly loaded dynamic code."));