bugGNU Octave - Bugs: bug #50593, version-rcfile: startup error...

 
 

bug #50593: version-rcfile: startup error 'startup' undefined near line 31 column 3

Submitter:  Ernst Reissner <ernstreissner>
Submitted:  Mon 20 Mar 2017 12:54:35 PM UTC
   
 
Category:  Interpreter Severity:  3 - Normal
Priority:  5 - Normal Item Group:  None
Status:  Fixed Assigned to:  None
Originator Name:  Open/Closed:  * Closed
Release:  * dev Operating System:  * Any
Fixed Release:  None Planned Release:  None
* Mandatory Fields

Add a New Comment Rich Markup
   

Mon 20 Mar 2017 04:43:25 PM UTC, comment #1: 

I checked in a change on the stable branch that prevents this (http://hg.savannah.gnu.org/hgweb/octave/rev/c0bfb20b0457).  I just looked at the return code from exist to make sure that what it had found was a file rather than a directory.

I checked in another change that makes Octave look only for the file "startup.m" (http://hg.savannah.gnu.org/hgweb/octave/rev/af5e8bfe03ad).  This is more correct because that is the name Matlab requires.

Rik <rik5>
Group administrator
Mon 20 Mar 2017 12:54:35 PM UTC, original submission:  

When starting octave in /usr/local/share/octave/4.3.0+/m,
(or according),
there is a directory startup.

In file scripts/startup/version-rcfile, we find

## For Matlab compatibility, run startup.m when starting Octave.
if (exist ("startup", "file"))
  startup;  # No arg list here since startup might be a script.
endif


If we start octave with octave --no-gui -V, i.e. verbose,
we obtain: error: 'startup' undefined near line 31 column 3

Line31 refers to version-rcfile.

To avoid this, let us write if (exist ("startup", "file") && ~exist ("startup", "dir")

Ernst Reissner <ernstreissner>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:
   
   
Comment:
   

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by rik5 (Posted a comment)
  • -email is unavailable- added by ernstreissner (Submitted the item)
  • -email is unavailable- added by ernstreissner
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

    Only group members can vote.

     

    Follow 3 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2017-03-20 rik5 StatusNone Fixed
        Open/ClosedOpen Closed
    2017-03-20 ernstreissner Carbon-Copy- Added -email is unavailable-

    Back to the top

    Powered by Savane 3.13-d3ae.
    Corresponding source code