public inbox for binutils@sourceware.org
 help / color / mirror / Atom feed
* PATCH: Fix default_binutils_run to check exit status
@ 2006-04-06 21:50 H. J. Lu
  2006-04-10 16:02 ` Nick Clifton
  0 siblings, 1 reply; 2+ messages in thread
From: H. J. Lu @ 2006-04-06 21:50 UTC (permalink / raw)
  To: binutils

default_binutils_run doesn't check exit status. If a program
segfaults and doesn't generate any output, default_binutils_run
think it is successful. This patch checks exit status.


H.J.
----
2006-04-06  H.J. Lu  <hongjiu.lu@intel.com>

	* lib/utils-lib.exp (default_binutils_run): Check exit status.

--- binutils/testsuite/lib/utils-lib.exp.status	2005-05-08 07:17:41.000000000 -0700
+++ binutils/testsuite/lib/utils-lib.exp	2006-04-06 12:59:45.000000000 -0700
@@ -73,6 +73,12 @@ proc default_binutils_run { prog progarg
     if {![string match "" $exec_output]} then {
 	send_log "$exec_output\n"
 	verbose "$exec_output"
+    } else {
+	if { [lindex $state 0] != 0 } {
+	    set exec_output "$prog exited with status [lindex $state 0]"
+	    send_log "$exec_output\n"
+	    verbose "$exec_output"
+	}
     }
     return $exec_output
 }

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: PATCH: Fix default_binutils_run to check exit status
  2006-04-06 21:50 PATCH: Fix default_binutils_run to check exit status H. J. Lu
@ 2006-04-10 16:02 ` Nick Clifton
  0 siblings, 0 replies; 2+ messages in thread
From: Nick Clifton @ 2006-04-10 16:02 UTC (permalink / raw)
  To: H. J. Lu; +Cc: binutils

Hi H. J.

> 2006-04-06  H.J. Lu  <hongjiu.lu@intel.com>
> 
> 	* lib/utils-lib.exp (default_binutils_run): Check exit status.

Approved - please apply.

Cheers
   Nick


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2006-04-10 15:57 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-04-06 21:50 PATCH: Fix default_binutils_run to check exit status H. J. Lu
2006-04-10 16:02 ` Nick Clifton

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).