Mercurial > octave
diff libinterp/corefcn/max.cc @ 20743:b6408331bfa2
eliminate more uses of error_state
* graphics.cc, input.cc, max.cc, rand.cc, __eigs__.cc, ov-class.cc,
ov-classdef.cc, ov.cc, octave.cc: Eliminate more uses of error_state.
author | John W. Eaton <jwe@octave.org> |
---|---|
date | Mon, 23 Nov 2015 23:23:57 -0500 |
parents | f90c8372b7ba |
children | 8bb38ba1bad6 |
line wrap: on
line diff
--- a/libinterp/corefcn/max.cc Mon Nov 23 21:00:14 2015 -0500 +++ b/libinterp/corefcn/max.cc Mon Nov 23 23:23:57 2015 -0500 @@ -240,7 +240,8 @@ if (nargin == 3) { dim = args(2).int_value (true) - 1; - if (error_state || dim < 0) + + if (dim < 0) { error ("%s: DIM must be a valid dimension", func); return retval; @@ -901,7 +902,8 @@ if (nargin == 2) { dim = args(1).int_value (true) - 1; - if (error_state || dim < 0) + + if (dim < 0) { error ("%s: DIM must be a valid dimension", func); return retval;