[Top][All Lists]

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

Re: pathnames containing spaces

From: Earnie Boyd
Subject: Re: pathnames containing spaces
Date: Wed, 28 Jan 2004 08:08:50 -0500
User-agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.5) Gecko/20031007

Scott James Remnant wrote:

It should also be noted that Libtool suffers heavily from this problem
also.  The shell uses spaces as separators, which means Libtool isn't
even able to install to a directory containing a space:

dependency_libs="-L/mnt/Program Files/unix/lib -lfoo"

comes out as three arguments, and quoting the -L argument doesn't
actually solve that.

As well as many other programs, utilities and scripts. White space has always been used as a delimiter for argument grokking purposes. Quoting the space only helps in some instances and to some point. If the path with a space is stored or even passed to another process then you've got to store or pass the quoting mechanisms with it as well.

Although file systems support a space in it's filenames it is discouraged from use for practical application purposes. This discouragement is what makes the use of space in filenames non-portable, not necessarily the file system itself. It is much easier to apply workarounds to this problem than it is to program for the problem. The chance that you will have further problems with the space if you fix it in one place is, IMNSHO, about 99.99% certain.

Good luck with fixing the white space problems in every process that reads arguments and uses white space as a delimiter of some sort.


reply via email to

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