[OctDev] Bug in Octave 3.0.0
Dmitri A. Sergatskov
dasergatskov at gmail.com
Sun Mar 30 00:30:52 CDT 2008
On Sat, Mar 29, 2008 at 11:42 PM, Chris Tandiono
<christandiono at berkeley.edu> wrote:
> When using the run command, the working directory is not the expected
> working directory. Should this be changed? I don't really know.
>
> octave-3.0.0:8> pwd
> ans = /Users/chris/Desktop
> octave-3.0.0:9> run ../checker.m
> error: run: file must exist and be a valid Octave script file
> error: evaluating if command near line 43, column 2
> error: evaluating if command near line 39, column 5
> error: evaluating if command near line 38, column 3
> error: called from `run' in file `/Applications/Octave.app/Contents/
> Resources/share/octave/3.0.0/m/miscellaneous/run.m'
> octave-3.0.0:9> cd ..
> octave-3.0.0:10> ls
> *snip*
> checker.m
>
I think there is a bug in run.m (line 43).
Instead of
if (! exist (s, "file") || ! strcmp (ext, ".m"))
There should be
if (! exist (f, "file") || ! strcmp (ext, ".m"))
Regards,
Dmitri.
p.s. CC to bug@!octave.org since run.m is an octave's core function.
--
More information about the Bug-octave
mailing list