mirror of
https://github.com/bminor/binutils-gdb.git
synced 2025-11-16 12:34:43 +00:00
gdb/solib: make solib_ops::solib_create_inferior_hook optional
The solib-target implementation of solib_create_inferior_hook is empty. Make that method / function pointer optional. Change-Id: Ie27b8d2c4fc6df74069ac8f88fbe69cf88a6662d Reviewed-By: Guinevere Larsen <guinevere@redhat.com>
This commit is contained in:
@@ -256,12 +256,6 @@ solib_target_current_sos (void)
|
||||
return sos;
|
||||
}
|
||||
|
||||
static void
|
||||
solib_target_solib_create_inferior_hook (int from_tty)
|
||||
{
|
||||
/* Nothing needed. */
|
||||
}
|
||||
|
||||
static void
|
||||
solib_target_relocate_section_addresses (solib &so, target_section *sec)
|
||||
{
|
||||
@@ -396,7 +390,7 @@ const solib_ops solib_target_so_ops =
|
||||
solib_target_relocate_section_addresses,
|
||||
nullptr,
|
||||
nullptr,
|
||||
solib_target_solib_create_inferior_hook,
|
||||
nullptr,
|
||||
solib_target_current_sos,
|
||||
nullptr,
|
||||
solib_target_in_dynsym_resolve_code,
|
||||
|
||||
@@ -1317,7 +1317,8 @@ solib_create_inferior_hook (int from_tty)
|
||||
{
|
||||
const solib_ops *ops = gdbarch_so_ops (current_inferior ()->arch ());
|
||||
|
||||
ops->solib_create_inferior_hook (from_tty);
|
||||
if (ops->solib_create_inferior_hook != nullptr)
|
||||
ops->solib_create_inferior_hook (from_tty);
|
||||
}
|
||||
|
||||
/* See solib.h. */
|
||||
|
||||
Reference in New Issue
Block a user