Mail Archives: djgpp-workers/2001/01/14/11:02:59
From: | "Tim Van Holder" <tim DOT van DOT holder AT pandora DOT be>
|
To: | <djgpp-workers AT delorie DOT com>
|
Subject: | putpath minipatch
|
Date: | Sun, 14 Jan 2001 17:03:55 +0100
|
Message-ID: | <NEBBIOJNGMKPNOBKHCGHOEJGCAAA.tim.van.holder@pandora.be>
|
MIME-Version: | 1.0
|
X-Priority: | 3 (Normal)
|
X-MSMail-Priority: | Normal
|
X-Mailer: | Microsoft Outlook IMO, Build 9.0.2416 (9.0.2910.0)
|
Importance: | Normal
|
X-MimeOLE: | Produced By Microsoft MimeOLE V5.50.4133.2400
|
X-MIME-Autoconverted: | from quoted-printable to 8bit by delorie.com id LAA20236
|
Reply-To: | djgpp-workers AT delorie DOT com
|
While still not providing an entirely clean way to deal with /dev paths, the
small patch below at least treats '/dev/env' as a valid path, instead of
turning it into 'env', which ends up as './env'.
This may not fix mkinstalldirs, but at least it provides a sane result (i.e.
it creates c:/dev and c:/dev/env, instead of c:/dev and c:/curdir/env).
diff -c -r1.5 putpath.c
*** putpath.c 1999/06/03 17:27:35 1.5
--- putpath.c 2001/01/14 15:59:02
***************
*** 50,55 ****
--- 50,58 ----
path = "nul";
else if (strcmp(p+5, "tty") == 0)
path = "con";
+ else if (strcmp(p+5, "env") == 0)
+ /* keep it as is to avoid referencing an 'env' directory in the current
+ dir */;
else if (((p[5] >= 'a' && p[5] <= 'z')
|| (p[5] >= 'A' && p[5] <= 'Z'))
&& (p[6] == '/' || p[6] == '\\' || p[6] == '\0'))
- Raw text -