delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp-workers/2002/06/30/11:15:17

Sender: rich AT phekda DOT freeserve DOT co DOT uk
Message-ID: <3D1F1BDE.85154475@phekda.freeserve.co.uk>
Date: Sun, 30 Jun 2002 15:55:26 +0100
From: Richard Dawe <rich AT phekda DOT freeserve DOT co DOT uk>
X-Mailer: Mozilla 4.77 [en] (X11; U; Linux 2.2.19 i586)
X-Accept-Language: de,fr
MIME-Version: 1.0
To: DJGPP workers <djgpp-workers AT delorie DOT com>
Subject: Re: gcc-3.1: old problem with temporary files
References: <3D08D753 DOT 9898 DOT 186F2D1 AT localhost> (pavenis AT lanet DOT lv) <3D08F9D5 DOT 4065 DOT 4B0BFF AT localhost> <3D139EAB DOT 9DCB25C9 AT phekda DOT freeserve DOT co DOT uk> <2950-Sat22Jun2002124302+0300-eliz AT is DOT elta DOT co DOT il>
Reply-To: djgpp-workers AT delorie DOT com

Hello.

Eli Zaretskii wrote:
>
> Richard Dawe wrote:
> >
> > I think there's actually a bug in _put_path. There's code to remove a
> > trailing slash, but it only does that for forward slashes.
> 
> We simply imitate the DOS/Windows behavior for backslashes (their
> system calls fail when there are extra trailing slashes), but emulate
> the Posix behavior with forward slashes.

Ah, OK.

> On balance, I'm not sure C:/temp\ is a case important enough to change
> the current behavior.

OK.

Incidentally, try something like:

    cd \\temp\\\\\\
    pwd

in the DJGPP port of bash and see what you get.

> What would be the user-level situation where such a file name
> could be born?

Hmmm, I don't know.

> > IMHO it should do this for backward slashes too. The diff below contains
> > a patch for this. So far I've only tested it with a demo program, but it
> > should be tested with more heavy-duty stuff, given how important
> > _put_path is.
> 
> Watch out for UNCs: we shouldn't break them, even though we don't
> really support them.
[snip]

I think the patch will break them.

Thanks, bye, Rich =]

-- 
Richard Dawe [ http://www.phekda.freeserve.co.uk/richdawe/ ]

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019