delorie.com/archives/browse.cgi | search |
Mailing-List: | contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm |
List-Subscribe: | <mailto:cygwin-subscribe AT sources DOT redhat DOT com> |
List-Archive: | <http://sources.redhat.com/ml/cygwin/> |
List-Post: | <mailto:cygwin AT sources DOT redhat DOT com> |
List-Help: | <mailto:cygwin-help AT sources DOT redhat DOT com>, <http://sources.redhat.com/ml/#faqs> |
Sender: | cygwin-owner AT sources DOT redhat DOT com |
Delivered-To: | mailing list cygwin AT sources DOT redhat DOT com |
Message-Id: | <39EB11FE.59B85677@ision.net> |
Date: | Mon, 16 Oct 2000 16:34:38 +0200 |
From: | Benjamin Riefenstahl <Benjamin DOT Riefenstahl AT ision DOT net> |
Organization: | ISION Internet AG |
X-Mailer: | Mozilla 4.05 [en] (Win16; I) |
MIME-Version: | 1.0 |
To: | cygwin AT sources DOT redhat DOT com |
Subject: | Re: Spaces in paths (was RE: Newbie: W2K and Mounting problem.) |
References: | <003901c0352c$dee38620$0600000a AT tired> |
Hi Dan, Dan Haynes wrote: > [...] I accidentally discovered that cmd.exe > treats the following identically: > > cd \usr \src > cd \usr\src > > I knew that cmd.exe always tried to "imagine" quotes when paths with spaces > were used, but I didn't realize is "patches up" misspelled names like this. The reasons (pl) for this can be explained: 1) On Windows, programs get passed the whole command line as one string. It's up to the program to interpret that string. By extension the same goes for internal commands of COMMAND.COM and CMD.EXE. The "cd" command has always treated the whole command line as the single argument, even when called without quotes. So the call above is equivalent to cd "\usr \src" 2) Spaces at the end of file names are not significant, because on a traditional 8.3 FAT file system, every name that was shorter than 8.3 was internally padded with spaces anyway. This seems to have been carried over to file systems with long file names. So "\usr" is the same as "\usr ", and "\usr\src" the same as "\usr \src". so long, benny -- ISION Internet AG Benjamin Riefenstahl mailto:benjamin DOT riefenstahl AT ision DOT net Ruhrstrasse 61 D-22761 Hamburg http://www.ision.net -- Want to unsubscribe from this list? Send a message to cygwin-unsubscribe AT sourceware DOT cygnus DOT com
webmaster | delorie software privacy |
Copyright © 2019 by DJ Delorie | Updated Jul 2019 |