diff options
author | Simon Marchi <simon.marchi@polymtl.ca> | 2024-07-11 12:38:31 -0400 |
---|---|---|
committer | Simon Marchi <simon.marchi@efficios.com> | 2024-07-15 14:34:12 -0400 |
commit | 89dc60d9570ff8f0f9757a6b0a8acd7204667c66 (patch) | |
tree | 72b988e76fadc444c9f2a08909233e9e25c87988 /gdb/target.c | |
parent | 98793b838c3cf99228d7a6d89918932f4effee24 (diff) | |
download | binutils-89dc60d9570ff8f0f9757a6b0a8acd7204667c66.zip binutils-89dc60d9570ff8f0f9757a6b0a8acd7204667c66.tar.gz binutils-89dc60d9570ff8f0f9757a6b0a8acd7204667c66.tar.bz2 |
gdb: split no_shared_libraries, command vs implementation
The `no_shared_libraries` function is currently used to implement the
`nosharedlibrary` command, but it also used internally by other
functions. This does not make a very good internal API.
Add the `no_shared_libraries_command` function to implement the CLI
command. Remove the unused parameters from `no_shared_libraries`.
Remove the `from_tty` parameter of `target_pre_inferior`, since it's now
unused.
Change-Id: I4fcba5ee1e0f7d250aab1a7b62b9ea16265fe962
Approved-By: Tom Tromey <tom@tromey.com>
Reviewed-By: Thiago Jung Bauermann <thiago.bauermann@linaro.org>
Diffstat (limited to 'gdb/target.c')
-rw-r--r-- | gdb/target.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/gdb/target.c b/gdb/target.c index 1b5aa11..0ca7087 100644 --- a/gdb/target.c +++ b/gdb/target.c @@ -2428,7 +2428,7 @@ info_target_command (const char *args, int from_tty) resets (things which might change between targets). */ void -target_pre_inferior (int from_tty) +target_pre_inferior () { /* Clear out solib state. Otherwise the solib state of the previous inferior might have survived and is entirely wrong for the new @@ -2452,7 +2452,7 @@ target_pre_inferior (int from_tty) memory regions and features. */ if (!gdbarch_has_global_solist (current_inferior ()->arch ())) { - no_shared_libraries (NULL, from_tty); + no_shared_libraries (); invalidate_target_mem_regions (); @@ -2504,7 +2504,7 @@ target_preopen (int from_tty) live process to a core of the same program. */ current_inferior ()->pop_all_targets_above (file_stratum); - target_pre_inferior (from_tty); + target_pre_inferior (); } /* See target.h. */ |