[Top][All Lists]

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

Re: [Nano-devel] [PATCH] browser: replace newpath by path and present_pa

From: Benno Schulenberg
Subject: Re: [Nano-devel] [PATCH] browser: replace newpath by path and present_path
Date: Tue, 12 Jul 2016 22:16:51 +0200

On Tue, Jul 12, 2016, at 14:01, Rishabh Dave wrote:
> On Fri, Jul 8, 2016 at 1:01 AM, Benno Schulenberg
> <address@hidden> wrote:
> > Are you sure you want to make path null?  Don't you want to
> > restore it from present_path?  Have you tested this route
> > through the code?  You know: --operatingdir, ^R ^T, try to
> > go outside, ^L.
> Well, I first re-wrote the patch to remain up to the latest commit.
> And then on running the test, I couldn't find anything.

If you run 'src/nano --oper=.' and then type ^R ^T M-G /home <Enter>
then move the cursor around a bit (just for fun), and then type ^L,
it says: "Cannot open directory: No such file or directory".  What?
Message doesn't make sense.

But when you don't make path NULL but restore it from present_path,
that message doesn't occur.  Which is the right thing.

Going through the patch...  This (at line 333) is not needed:

+           path = mallocstrcpy(path, present_path);

When kbinput is a key_winch, path hasn't changed, so there is no need
to set it again.  (Formerly, newpath had to be set to force a reread,
but that mechanism is gone now.)

When you've fixed that, and you're content, send a signed-off patch.


-- - Access your email from home and the web

reply via email to

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