diff options
author | Andrew Burgess <aburgess@redhat.com> | 2022-10-06 09:35:18 +0100 |
---|---|---|
committer | Andrew Burgess <aburgess@redhat.com> | 2022-10-06 10:01:15 +0100 |
commit | 80e0c6dc91f52fad32c3ff3cf20da889d77013ac (patch) | |
tree | 768dbcc5a44572923edab555d74f76875eed362c | |
parent | d8a77e4c8043c645c3c7a07a042c112053715e95 (diff) | |
download | gdb-80e0c6dc91f52fad32c3ff3cf20da889d77013ac.zip gdb-80e0c6dc91f52fad32c3ff3cf20da889d77013ac.tar.gz gdb-80e0c6dc91f52fad32c3ff3cf20da889d77013ac.tar.bz2 |
gdb: add missing nullptr checks in bpstat_check_breakpoint_conditions
Add a couple of missing nullptr checks in the function
bpstat_check_breakpoint_conditions.
No user visible change after this commit.
-rw-r--r-- | gdb/breakpoint.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/gdb/breakpoint.c b/gdb/breakpoint.c index 29a0294..a3a154c 100644 --- a/gdb/breakpoint.c +++ b/gdb/breakpoint.c @@ -5358,7 +5358,7 @@ bpstat_check_breakpoint_conditions (bpstat *bs, thread_info *thread) else cond = bl->cond.get (); - if (cond && b->disposition != disp_del_at_next_stop) + if (cond != nullptr && b->disposition != disp_del_at_next_stop) { int within_current_scope = 1; struct watchpoint * w; @@ -5430,7 +5430,7 @@ bpstat_check_breakpoint_conditions (bpstat *bs, thread_info *thread) value_free_to_mark (mark); } - if (cond && !condition_result) + if (cond != nullptr && !condition_result) { infrun_debug_printf ("condition_result = false, not stopping"); bs->stop = 0; |