diff mbox

[Fortran] Follow up patch to the backtrace changes

Message ID 4DCE87EF.5030405@net-b.de
State New
Headers show

Commit Message

Tobias Burnus May 14, 2011, 1:47 p.m. UTC
This patch re-adds the option -f(no-)backtrace as Ignored to improve 
backward compatibility.

Additionally, for ERROR STOP, no backtrace is printed any more.

Build on x86-64-linux.
OK for the trunk?

Tobias

Comments

Jerry DeLisle May 14, 2011, 2:21 p.m. UTC | #1
On 05/14/2011 06:47 AM, Tobias Burnus wrote:
> This patch re-adds the option -f(no-)backtrace as Ignored to improve backward
> compatibility.
>
> Additionally, for ERROR STOP, no backtrace is printed any more.
>
> Build on x86-64-linux.
> OK for the trunk?
>
> Tobias

OK, thanks,

Jerry
diff mbox

Patch

2011-05-14  Tobias Burnus  <burnus@net-b.de>

	* lang.opt (fdump-core): Re-add as ignored option
	for backward compatibility.

2011-05-14  Tobias Burnus  <burnus@net-b.de>

	* runtime/stop.c (error_stop_string, error_stop_numeric):
	Do not backtrace for ERROR STOP.

diff --git a/gcc/fortran/lang.opt b/gcc/fortran/lang.opt
index a056c5c..1a3d073 100644
--- a/gcc/fortran/lang.opt
+++ b/gcc/fortran/lang.opt
@@ -366,6 +366,10 @@  fdollar-ok
 Fortran
 Allow dollar signs in entity names
 
+fdump-core
+Fortran Ignore
+Does nothing. Preserved for backward compatibility.
+
 fdump-fortran-original
 Fortran
 Display the code tree after parsing
diff --git a/libgfortran/runtime/stop.c b/libgfortran/runtime/stop.c
index 2efe239..4c3a0f9 100644
--- a/libgfortran/runtime/stop.c
+++ b/libgfortran/runtime/stop.c
@@ -92,7 +92,7 @@  error_stop_string (const char *string, GFC_INTEGER_4 len)
   (void) sizeof (w); /* Avoid compiler warning about not using w.  */
   estr_write ("\n");
 
-  sys_abort ();
+  exit (1);
 }
 
 
@@ -106,8 +106,5 @@  void
 error_stop_numeric (GFC_INTEGER_4 code)
 {
   st_printf ("ERROR STOP %d\n", (int) code);
-  if (options.backtrace == 1
-      || (options.backtrace == -1 && compile_options.backtrace == 1))
-    show_backtrace ();
   exit (code);
 }