emacs-devel
[Top][All Lists]
Advanced

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

Re: Multibyte and unibyte file names


From: Paul Eggert
Subject: Re: Multibyte and unibyte file names
Date: Wed, 23 Jan 2013 15:38:51 -0800
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130110 Thunderbird/17.0.2

On 01/23/13 11:04, Eli Zaretskii wrote:
> encoding a file name,
> then removing its last "slash" as above, then decoding it again will
> yield a wrong or even an invalid string, right?

Yes, the code may be wrong for MS-Windows,
but since the problem can't possibly occur in a POSIXish
system, the code is correct as-is on POSIX.  It's correct to
always treat a '/' byte as a directory separator, no matter what
the file name coding system is.  This is de facto true already,
and as I understand it the next version of POSIX will require this
to be true for all encodings.  Similarly, the next POSIX will
guarantee that '.' always stands for itself, in any encoding.



reply via email to

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