Mercurial > hg > octave-terminal
changeset 12880:ff264eae88cf
textread.m, textscan.m: Read entire file when format repeat count is -1
* textread.m, textscan.m: Read entire file when format repeat count is -1.
author | Rik <octave@nomad.inbox5.com> |
---|---|
date | Sun, 24 Jul 2011 22:11:26 -0700 |
parents | c3b305e7e59f |
children | 49553ea11764 |
files | scripts/io/textread.m scripts/io/textscan.m |
diffstat | 2 files changed, 2 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/scripts/io/textread.m +++ b/scripts/io/textread.m @@ -78,7 +78,7 @@ nlines = Inf; endif - if (isfinite (nlines)) + if (isfinite (nlines) && (nlines >= 0)) str = tmp_str = ""; n = 0; ## FIXME: Can this be done without slow loop?
--- a/scripts/io/textscan.m +++ b/scripts/io/textscan.m @@ -139,7 +139,7 @@ fskipl (fid, varargin{headerlines + 1}); args(headerlines:headerlines+1) = []; endif - if (isfinite (nlines)) + if (isfinite (nlines) && (nlines >= 0)) str = tmp_str = ""; n = 0; ## FIXME: Can this be done without slow loop?