This is the mail archive of the gdb-cvs@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[binutils-gdb] Remove redundant WIFSTOPPED check


https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=80aea927cc7bf97a2bc22e1fb2111c52be295e8b

commit 80aea927cc7bf97a2bc22e1fb2111c52be295e8b
Author: Yao Qi <yao.qi@linaro.org>
Date:   Fri Mar 18 14:28:14 2016 +0000

    Remove redundant WIFSTOPPED check
    
    WIFSTOPPED is checked linux_wstatus_maybe_breakpoint, so WIFSTOPPED
    in "WIFSTOPPED (wstat) && linux_wstatus_maybe_breakpoint (wstat)"
    is redundant.  This patch removes WIFSTOPPED check.
    
    gdb/gdbserver:
    
    2016-03-18  Yao Qi  <yao.qi@linaro.org>
    
    	* linux-low.c (linux_low_filter_event): Remove redundant
    	WIFSTOPPED check together with linux_wstatus_maybe_breakpoint.

Diff:
---
 gdb/gdbserver/ChangeLog   | 5 +++++
 gdb/gdbserver/linux-low.c | 2 +-
 2 files changed, 6 insertions(+), 1 deletion(-)

diff --git a/gdb/gdbserver/ChangeLog b/gdb/gdbserver/ChangeLog
index dda87b0..ecc5281 100644
--- a/gdb/gdbserver/ChangeLog
+++ b/gdb/gdbserver/ChangeLog
@@ -1,3 +1,8 @@
+2016-03-18  Yao Qi  <yao.qi@linaro.org>
+
+	* linux-low.c (linux_low_filter_event): Remove redundant
+	WIFSTOPPED check together with linux_wstatus_maybe_breakpoint.
+
 2016-03-09  Marcin KoÅ?cielnicki  <koriakin@0x04.net>
 
 	* linux-ppc-low.c (ppc_supports_tracepoints): New function.
diff --git a/gdb/gdbserver/linux-low.c b/gdb/gdbserver/linux-low.c
index c008847..183cdd9 100644
--- a/gdb/gdbserver/linux-low.c
+++ b/gdb/gdbserver/linux-low.c
@@ -2443,7 +2443,7 @@ linux_low_filter_event (int lwpid, int wstat)
 	}
     }
 
-  if (WIFSTOPPED (wstat) && linux_wstatus_maybe_breakpoint (wstat))
+  if (linux_wstatus_maybe_breakpoint (wstat))
     {
       if (save_stop_reason (child))
 	have_stop_pc = 1;


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]