diff options
author | Simon Marchi <simon.marchi@polymtl.ca> | 2022-01-16 21:21:24 -0500 |
---|---|---|
committer | Simon Marchi <simon.marchi@polymtl.ca> | 2022-01-18 13:44:32 -0500 |
commit | c68665c7260985ac8497ccafcea961f4a261c675 (patch) | |
tree | e191f41840a74d69d137aac3772bef48b04e3367 /gdbserver/server.cc | |
parent | d66beefaf6334d69b638b3300e264f7996c572dc (diff) | |
download | binutils-gdb-c68665c7260985ac8497ccafcea961f4a261c675.tar.gz |
gdbserver: turn debug_threads into a boolean
debug_threads is always used as a boolean. Except in ax.cc and
tracepoint.cc. These files have their own macros that use
debug_threads, and have a concept of verbosity level. But they both
have a single level, so it's just a boolean in the end.
Remove this concept of level. If we ever want to re-introduce it, I
think it will be better implemented in a more common location.
Change debug_threads to bool and adjust some users that were treating it
as an int.
Change-Id: I137f596eaf763a08c977dd74417969cedfee9ecf
Diffstat (limited to 'gdbserver/server.cc')
-rw-r--r-- | gdbserver/server.cc | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/gdbserver/server.cc b/gdbserver/server.cc index 07f119dc6a1..021c7adc308 100644 --- a/gdbserver/server.cc +++ b/gdbserver/server.cc @@ -1380,12 +1380,12 @@ handle_monitor_command (char *mon, char *own_buf) { if (strcmp (mon, "set debug 1") == 0) { - debug_threads = 1; + debug_threads = true; monitor_output ("Debug output enabled.\n"); } else if (strcmp (mon, "set debug 0") == 0) { - debug_threads = 0; + debug_threads = false; monitor_output ("Debug output disabled.\n"); } else if (strcmp (mon, "set debug-hw-points 1") == 0) @@ -3814,7 +3814,7 @@ captured_main (int argc, char *argv[]) *next_arg = NULL; } else if (strcmp (*next_arg, "--debug") == 0) - debug_threads = 1; + debug_threads = true; else if (startswith (*next_arg, "--debug-format=")) { std::string error_msg |