changeset 1022:d3790919922e

[project @ 1995-01-11 00:45:09 by jwe]
author jwe
date Wed, 11 Jan 1995 00:46:50 +0000
parents 4ebc7911ab98
children 914348f891f0
files scripts/linear-algebra/orth.m src/octave.cc
diffstat 2 files changed, 10 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/scripts/linear-algebra/orth.m	Tue Jan 10 23:20:48 1995 +0000
+++ b/scripts/linear-algebra/orth.m	Wed Jan 11 00:46:50 1995 +0000
@@ -21,7 +21,7 @@
 
   if (nargin == 1)
     tol = max (size (A)) * s (1) * eps;
-  else if (nargin != 2)
+  elseif (nargin != 2)
     usage ("orth (A [, tol])"); 
   endif
 
--- a/src/octave.cc	Tue Jan 10 23:20:48 1995 +0000
+++ b/src/octave.cc	Wed Jan 11 00:46:50 1995 +0000
@@ -942,6 +942,15 @@
 
       int status = cmd.close ();
 
+// The value in status is as returned by waitpid.  If the process
+// exited normally, extract the actual exit status of the command.
+// Otherwise, return 127 as a failure code.
+
+      if ((status & 0xff) == 0)
+	status = (status & 0xff00) >> 8;
+      else
+	status = 127;
+
       if (nargout > 0 || nargin > 1)
 	{
 	  char *msg = output_buf.str ();