* solib-svr4.c (enable_break): Call
authorJoseph Myers <joseph@codesourcery.com>
Tue, 10 Nov 2009 21:36:48 +0000 (21:36 +0000)
committerJoseph Myers <joseph@codesourcery.com>
Tue, 10 Nov 2009 21:36:48 +0000 (21:36 +0000)
gdbarch_convert_from_func_ptr_addr on results of looking up
fallback symbol names.

gdb/ChangeLog
gdb/solib-svr4.c

index ced2fe0834e687b36dccf27f664d35dcbd0c6dbd..5cd6df921b784463f7639662436ccf614a579dee 100644 (file)
@@ -1,3 +1,9 @@
+2009-11-10  Joseph Myers  <joseph@codesourcery.com>
+
+       * solib-svr4.c (enable_break): Call
+       gdbarch_convert_from_func_ptr_addr on results of looking up
+       fallback symbol names.
+
 2009-11-10  Daniel Gutson  <dgutson@codesourcery.com>
 
        * procfs.c (procfs_do_thread_registers): Added a call to fetch
index d685ea5a4d7a08705308857e5cb536550b3572bd..21055f678d6eb8765c75b319acb16c34e331234d 100644 (file)
@@ -1436,8 +1436,11 @@ enable_break (struct svr4_info *info)
       msymbol = lookup_minimal_symbol (*bkpt_namep, NULL, symfile_objfile);
       if ((msymbol != NULL) && (SYMBOL_VALUE_ADDRESS (msymbol) != 0))
        {
-         create_solib_event_breakpoint (target_gdbarch,
-                                        SYMBOL_VALUE_ADDRESS (msymbol));
+         sym_addr = SYMBOL_VALUE_ADDRESS (msymbol);
+         sym_addr = gdbarch_convert_from_func_ptr_addr (target_gdbarch,
+                                                        sym_addr,
+                                                        &current_target);
+         create_solib_event_breakpoint (target_gdbarch, sym_addr);
          return 1;
        }
     }
@@ -1447,8 +1450,11 @@ enable_break (struct svr4_info *info)
       msymbol = lookup_minimal_symbol (*bkpt_namep, NULL, symfile_objfile);
       if ((msymbol != NULL) && (SYMBOL_VALUE_ADDRESS (msymbol) != 0))
        {
-         create_solib_event_breakpoint (target_gdbarch,
-                                        SYMBOL_VALUE_ADDRESS (msymbol));
+         sym_addr = SYMBOL_VALUE_ADDRESS (msymbol);
+         sym_addr = gdbarch_convert_from_func_ptr_addr (target_gdbarch,
+                                                        sym_addr,
+                                                        &current_target);
+         create_solib_event_breakpoint (target_gdbarch, sym_addr);
          return 1;
        }
     }