octave-bug-tracker
[Top][All Lists]
Advanced

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

[Octave-bug-tracker] [bug #43426] run doesn't return to original working


From: Andreas Weber
Subject: [Octave-bug-tracker] [bug #43426] run doesn't return to original working directory if using relative path
Date: Thu, 16 Oct 2014 11:47:56 +0000
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20140924 Firefox/24.0 Iceweasel/24.8.1

URL:
  <http://savannah.gnu.org/bugs/?43426>

                 Summary: run doesn't return to original working directory if
using relative path
                 Project: GNU Octave
            Submitted by: andy1978
            Submitted on: Thu 16 Oct 2014 11:47:55 AM GMT
                Category: None
                Severity: 3 - Normal
                Priority: 5 - Normal
              Item Group: Regression
                  Status: None
             Assigned to: None
         Originator Name: 
        Originator Email: 
             Open/Closed: Open
         Discussion Lock: Any
                 Release: dev
        Operating System: Any

    _______________________________________________________

Details:

Since cset http://hg.savannah.gnu.org/hgweb/octave/rev/1363d909c577 (for
bug#41543) run doesn't return back to the original working directory if using
a relative path.

See attached archive and run "show_runbug.m" (run('../doit.m')) in octave. The
path isn't changed back because there is a comparison

  if (strcmp (d, pwd ()))
    cd (wd);
  endif


and d is "..". I first thought it would be simple as changing this to

  if (strcmp ( make_absolute_filename (d), pwd ()))


but make_absolute_filename("..") returns a trailing "/" which pwd () doesn't.





    _______________________________________________________

File Attachments:


-------------------------------------------------------
Date: Thu 16 Oct 2014 11:47:55 AM GMT  Name: runbug.tar.gz  Size: 227B   By:
andy1978

<http://savannah.gnu.org/bugs/download.php?file_id=32281>

    _______________________________________________________

Reply to this item at:

  <http://savannah.gnu.org/bugs/?43426>

_______________________________________________
  Message sent via/by Savannah
  http://savannah.gnu.org/




reply via email to

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