]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commitdiff
testsuite: fix gdb_exit for MinGW target
authorRohr, Stephan <stephan.rohr@intel.com>
Mon, 24 Mar 2025 13:05:33 +0000 (13:05 +0000)
committerStephan Rohr <stephan.rohr@intel.com>
Wed, 14 May 2025 16:14:29 +0000 (09:14 -0700)
GDB is not properly exited via 'remote_close host' when running the
testsuite in a MinGW environment.  Use the 'quit' command to properly
exit the GDB debugging session.

Approved-By: Tom Tromey <tom@tromey.com>
gdb/testsuite/lib/gdb.exp

index 1b04cdc7e2814c8b901728365b220784c0ad6b85..49ef0d54654f257e85c3849ce1fbb18de80e9917 100644 (file)
@@ -2301,7 +2301,8 @@ proc default_gdb_exit {} {
        }
     }
 
-    if { [is_remote host] && [board_info host exists fileid] } {
+    if { ([is_remote host] && [board_info host exists fileid])
+        || [istarget *-*-mingw*] } {
        send_gdb "quit\n"
        gdb_expect 10 {
            -re "y or n" {