Path: csiph.com!usenet.pasdenom.info!gegeweb.org!eternal-september.org!feeder.eternal-september.org!mx04.eternal-september.org!.POSTED!not-for-mail From: Jim Janney Newsgroups: comp.lang.java.programmer Subject: Re: Space in 'My Documents' directory not fixed by quoting or \ escaping Date: Tue, 29 May 2012 16:37:00 -0600 Organization: absinthe will make my art grow stronger Lines: 35 Message-ID: References: <4fc4c1cb$0$6931$e4fe514c@news2.news.xs4all.nl> <23u9s7tr13usskfhim78anlj5g8pe3q9l1@4ax.com> <899d499e-c1ad-4863-b941-575aaaac1c4b@googlegroups.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Injection-Info: mx04.eternal-september.org; posting-host="dZdavj/jUDynNQgDq5jkeA"; logging-data="575"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/1nlBXgxD/Bv1BrvfQnI8w" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.1 (gnu/linux) Cancel-Lock: sha1:CdpeX+gKI8TTPMmtPvXrXgCz4MY= sha1:Nu4r9u0RixvgJgBV3809SmVJUJk= Xref: csiph.com comp.lang.java.programmer:14921 glen herrmannsfeldt writes: > Lew wrote: > > (snip) >>> But since using "/" as a path element seprator in a command line >>> will cause trouble, people tend to avoid using them as such. > >> That is interesting to me. What trouble? > >> I have used forward slashes as path element separators in Windows >> command-line commands. I don't recall that it caused any trouble. > > The system calls, such as OPEN, accept either / or \. > (C programmers use / for #include files, knowing it will work > on unix or DOS/Windows, at least since DOS 3.2.) > > The system command line utilities, such as DIR and COPY use / for > options, and won't accept it as part of a file path. > > Other command line utilities (that don't come with DOS/Windows) > that don't use / for options likely will accept /. > > The Sourceforge UNXUTILS, unix-like utilities for WIN32, > for example, should accept /. In early versions of MS-DOS you could put a line in CONFIG.SYS to set the switch character to something else, usually -, which then freed up / for use in file names. This eventually went away, I don't remember exactly when. The problem was never in the API but in user code that parsed command lines. -- Jim Janney