octave-maintainers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Octave's exit status


From: Julien Bect
Subject: Re: Octave's exit status
Date: Sun, 11 Dec 2016 13:35:50 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Icedove/45.4.0

Le 09/12/2016 à 20:13, John W. Eaton a écrit :
On 12/09/2016 02:06 PM, Julien Bect wrote:
Le 09/12/2016 à 15:33, John W. Eaton a écrit :

Yes, Octave should exit with a non-zero status if there is a syntax
error.  But the real bug here is the unhandled execution exception.
That shouldn't happen.  I'll take a look at fixing that.

Note that this happens with any error, not just syntax errors. For
instance:

$ octave --eval 'error ("toto")'
error: toto
error: unhandled execution exception -- eval failed

$ echo $?
0

I pushed the following changeset to stable:

  http://hg.savannah.gnu.org/hgweb/octave/rev/233fb529184b

It should fix the problem for parse or evaluation errors.

jwe

Yes, I confirm that I get now an exit code equal to 1 for both examples.

I think that is an important bugfix, that would justify by itself a 4.2.1 bugfix release ;-)

@++
Julien



reply via email to

[Prev in Thread] Current Thread [Next in Thread]