X-Git-Url: http://drtracing.org/?a=blobdiff_plain;f=gdb%2Fdtrace-probe.c;h=ce96037be21fe210b8462ad65e0b18121d0c2618;hb=975f8708de015fb2b813edbf8b714f4777c57a41;hp=6494a8d7ccab3f4fef5fd53037c2f4b8d312203d;hpb=b811d2c2920ddcb1adcd438da38e90912b31f45f;p=deliverable%2Fbinutils-gdb.git diff --git a/gdb/dtrace-probe.c b/gdb/dtrace-probe.c index 6494a8d7cc..ce96037be2 100644 --- a/gdb/dtrace-probe.c +++ b/gdb/dtrace-probe.c @@ -520,7 +520,7 @@ dtrace_process_dof (asection *sect, struct objfile *objfile, std::vector> *probesp, struct dtrace_dof_hdr *dof) { - struct gdbarch *gdbarch = get_objfile_arch (objfile); + struct gdbarch *gdbarch = objfile->arch (); struct dtrace_dof_sect *section; int i; @@ -685,8 +685,7 @@ dtrace_probe::is_enabled () const CORE_ADDR dtrace_probe::get_relocated_address (struct objfile *objfile) { - return this->get_address () + ANOFFSET (objfile->section_offsets, - SECT_OFF_DATA (objfile)); + return this->get_address () + objfile->data_section_offset (); } /* Implementation of the get_argument_count method. */ @@ -861,7 +860,7 @@ dtrace_static_probe_ops::get_probes else complaint (_("could not obtain the contents of" "section '%s' in objfile `%s'."), - sect->name, abfd->filename); + bfd_section_name (sect), bfd_get_filename (abfd)); xfree (dof); } @@ -897,8 +896,9 @@ info_probes_dtrace_command (const char *arg, int from_tty) info_probes_for_spops (arg, from_tty, &dtrace_static_probe_ops); } +void _initialize_dtrace_probe (); void -_initialize_dtrace_probe (void) +_initialize_dtrace_probe () { all_static_probe_ops.push_back (&dtrace_static_probe_ops);