Blame SOURCES/gdb-archer-next-over-throw-cxx-exec.patch

2c2fa1
Archer-upstreamed:
2c2fa1
http://sourceware.org/ml/archer/2010-q2/msg00031.html
2c2fa1
2c2fa1
--- ./gdb/testsuite/gdb.cp/cxxexec.cc	1970-01-01 01:00:00.000000000 +0100
2c2fa1
+++ ./gdb/testsuite/gdb.cp/cxxexec.cc	2010-05-29 01:18:56.000000000 +0200
2c2fa1
@@ -0,0 +1,25 @@
2c2fa1
+/* This test script is part of GDB, the GNU debugger.
2c2fa1
+
2c2fa1
+   Copyright 2010 Free Software Foundation, Inc.
2c2fa1
+
2c2fa1
+   This program is free software; you can redistribute it and/or modify
2c2fa1
+   it under the terms of the GNU General Public License as published by
2c2fa1
+   the Free Software Foundation; either version 3 of the License, or
2c2fa1
+   (at your option) any later version.
2c2fa1
+
2c2fa1
+   This program is distributed in the hope that it will be useful,
2c2fa1
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
2c2fa1
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
2c2fa1
+   GNU General Public License for more details.
2c2fa1
+
2c2fa1
+   You should have received a copy of the GNU General Public License
2c2fa1
+   along with this program.  If not, see <http://www.gnu.org/licenses/>.  */
2c2fa1
+
2c2fa1
+#include <unistd.h>
2c2fa1
+
2c2fa1
+int
2c2fa1
+main()
2c2fa1
+{
2c2fa1
+  execlp ("true", "true", NULL);
2c2fa1
+  return 1;
2c2fa1
+}
2c2fa1
--- ./gdb/testsuite/gdb.cp/cxxexec.exp	1970-01-01 01:00:00.000000000 +0100
2c2fa1
+++ ./gdb/testsuite/gdb.cp/cxxexec.exp	2010-05-29 01:29:25.000000000 +0200
2c2fa1
@@ -0,0 +1,51 @@
2c2fa1
+# Copyright 2010 Free Software Foundation, Inc.
2c2fa1
+
2c2fa1
+# This program is free software; you can redistribute it and/or modify
2c2fa1
+# it under the terms of the GNU General Public License as published by
2c2fa1
+# the Free Software Foundation; either version 3 of the License, or
2c2fa1
+# (at your option) any later version.
2c2fa1
+#
2c2fa1
+# This program is distributed in the hope that it will be useful,
2c2fa1
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
2c2fa1
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
2c2fa1
+# GNU General Public License for more details.
2c2fa1
+#
2c2fa1
+# You should have received a copy of the GNU General Public License
2c2fa1
+# along with this program.  If not, see <http://www.gnu.org/licenses/>.
2c2fa1
+
2c2fa1
+if { [skip_cplus_tests] } { continue }
2c2fa1
+
2c2fa1
+set testfile cxxexec
2c2fa1
+if { [prepare_for_testing ${testfile}.exp ${testfile} ${testfile}.cc {c++ debug}] } {
2c2fa1
+    return -1
2c2fa1
+}
2c2fa1
+
2c2fa1
+runto_main
2c2fa1
+
2c2fa1
+# We could stop after `continue' again at `main'.
2c2fa1
+delete_breakpoints
2c2fa1
+
2c2fa1
+set test "p _Unwind_DebugHook"
2c2fa1
+gdb_test_multiple $test $test {
2c2fa1
+    -re " = .* 0x\[0-9a-f\].*\r\n$gdb_prompt $" {
2c2fa1
+	pass $test
2c2fa1
+    }
2c2fa1
+    -re "\r\nNo symbol .*\r\n$gdb_prompt $" {
2c2fa1
+	xfail $test
2c2fa1
+	untested ${testfile}.exp
2c2fa1
+	return -1
2c2fa1
+    }
2c2fa1
+}
2c2fa1
+
2c2fa1
+set test continue
2c2fa1
+gdb_test_multiple $test $test {
2c2fa1
+    -re "Cannot access memory at address 0x\[0-9a-f\]+\r\n$gdb_prompt $" {
2c2fa1
+	fail $test
2c2fa1
+    }
2c2fa1
+    -re "\r\n$gdb_prompt $" {
2c2fa1
+	pass $test
2c2fa1
+    }
2c2fa1
+}
2c2fa1
+
2c2fa1
+# `info inferiors' can show <null> on older GDBs.
2c2fa1
+gdb_test "info threads" "info threads" "program finished"