[ARM, thumb] Fix disassembling bug after reloading a symbol file
[deliverable/binutils-gdb.git] / gdb / testsuite / gdb.base / siginfo-addr.exp
index 236dd952cc7251e526ce7ad79e204fcc82b6ce58..ba2965db3a516c17580e09d920945ed9146267a5 100644 (file)
@@ -1,4 +1,4 @@
-# Copyright 2004-2013 Free Software Foundation, Inc.
+# Copyright 2004-2019 Free Software Foundation, Inc.
 
 # This program is free software; you can redistribute it and/or modify
 # it under the terms of the GNU General Public License as published by
@@ -26,42 +26,23 @@ if [target_info exists gdb,nosignals] {
     continue
 }
 
-if [gdb_skip_stdio_test "siginfo-addr.exp"] {
-    continue
-}
-
-
-set testfile siginfo-addr
-set srcfile ${testfile}.c
-set binfile ${objdir}/${subdir}/${testfile}
-if  { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable {debug}] != "" } {
-    untested "Couldn't compile ${srcfile}.c"
+standard_testfile
+if {[prepare_for_testing "failed to prepare" $testfile $srcfile debug]} {
     return -1
 }
 
-# get things started
-gdb_exit
-gdb_start
-gdb_reinitialize_dir $srcdir/$subdir
-gdb_load ${binfile}
-
 gdb_test "display/i \$pc"
 
 # Advance to main
-if { ![runto_main] } then {
-    gdb_suppress_tests;
+if ![runto_main] then {
+    fail "can't run to main"
+    return 0
 }
 
 # Run to the signal.
 gdb_test "continue" ".*Program received signal SIGSEGV.*" "continue to signal"
 
+gdb_breakpoint "pass"
+
 # Check for correct si_addr.
-set test "program exit"
-gdb_test_multiple "continue" "${test}" {
-    -re "Correct si_addr" {
-       pass "si_addr value"
-    }
-    -re "Got si_addr" {
-       fail "si_addr value"
-    }
-}
+gdb_test "continue" "Breakpoint .* pass .*" "correct si_addr"
This page took 0.025761 seconds and 4 git commands to generate.