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] Accept all-stop alternative in mi_expect_interrupt


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

commit a8d9763abd6c461d646034537633fb03f5eabfd1
Author: Simon Marchi <simon.marchi@ericsson.com>
Date:   Wed Mar 4 11:37:31 2015 -0500

    Accept all-stop alternative in mi_expect_interrupt
    
    When interrupting a thread in non-stop vs all-stop, the signal given in
    the MI *stopped event is not the same. Currently, mi_expect_interrupt only
    accepts the case for non-stop, so this adds the alternative for all-stop.
    
    gdb/testsuite/ChangeLog:
    
    	* lib/mi-support.exp (mi_expect_interrupt): Accept
    	alternative event for when in all-stop mode.

Diff:
---
 gdb/testsuite/ChangeLog          | 5 +++++
 gdb/testsuite/lib/mi-support.exp | 5 +++--
 2 files changed, 8 insertions(+), 2 deletions(-)

diff --git a/gdb/testsuite/ChangeLog b/gdb/testsuite/ChangeLog
index 6f97eda..1a76cc8 100644
--- a/gdb/testsuite/ChangeLog
+++ b/gdb/testsuite/ChangeLog
@@ -1,3 +1,8 @@
+2015-03-04  Simon Marchi  <simon.marchi@ericsson.com>
+
+	* lib/mi-support.exp (mi_expect_interrupt): Accept
+	alternative event for when in all-stop mode.
+
 2015-03-04  Pedro Alves  <palves@redhat.com>
 
 	* gdb.threads/thread-specific-bp.exp: Delete "info threads" test.
diff --git a/gdb/testsuite/lib/mi-support.exp b/gdb/testsuite/lib/mi-support.exp
index 20546f6..6827ef9 100644
--- a/gdb/testsuite/lib/mi-support.exp
+++ b/gdb/testsuite/lib/mi-support.exp
@@ -1195,8 +1195,9 @@ proc mi_expect_interrupt { test } {
 	set prompt_re "$mi_gdb_prompt$"
     }
 
-    set r "reason=\"signal-received\",signal-name=\"0\",signal-meaning=\"Signal 0\""
-
+    set r_nonstop "reason=\"signal-received\",signal-name=\"0\",signal-meaning=\"Signal 0\""
+    set r_allstop "reason=\"signal-received\",signal-name=\"SIGINT\",signal-meaning=\"Interrupt\""
+    set r "(${r_nonstop}|${r_allstop})"
     set any "\[^\n\]*"
 
     # A signal can land anywhere, just ignore the location


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