emacs-pretest-bug
[Top][All Lists]
Advanced

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

Re: visiting "~/Application Data" gets "~" instead


From: Stefan Monnier
Subject: Re: visiting "~/Application Data" gets "~" instead
Date: Fri, 11 Aug 2006 18:43:02 -0400
User-agent: Gnus/5.11 (Gnus v5.11) Emacs/22.0.50 (gnu/linux)

>> This doesn't explain why (find-file-noselect "~/") and
>> (find-file-noselect "~/Application Data/") return the same buffer.
>> Shouldn't they be differnet no matter what ~ expands to?
>> 
> find-file-noselect calls (abbreviate-file-name (expand-file-name FILE)),
> where expand-file-name is implemented in C and uses egetenv("HOME") to
> expand "~", while abbreviate-file-name compares against lisp variable
> abbreviated-home-dir, so if HOME is changed from inside Emacs, these two
> functions are not going to be consistent with each other. This doesn't
> explain the above by itself, but I'm sure if you dived deeper you would find
> the explanation.

That sounds credible, although it may be completely unrelated.
E.g. I can't reproduce the problem on my GNU/Linux machine.

> The question is - is this worth fixing? Is it reasonable for the user to
> change the environment variable HOME from within Emacs?

Of course it is reasonable.  Maybe not an important case, tho,


        Stefan






reply via email to

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