[RFA, fixincludes] add quotes around directory pathname

Sandra Loosemore sandra@codesourcery.com
Sat Jan 17 21:10:00 GMT 2009


The fixincl program has a place where it uses the getcwd() library call to get 
the current directory.  If you happen to have gotten to the current directory 
through a symbolic link, this call resolves the link.  I've run into a case 
where the "real" pathname of the installation directory contains an embedded 
space.... causing a bogus error when it is passed into a shell command by 
fixincl without being quoted.  This patch fixes it by adding quotes.  If we 
weren't in stage 4, I would have just committed this as obvious, but I figure 
I'd better leave it up to the maintainers to decide if this is appropriate.  :-)

FWIW, the fixincludes shell scripts fall over badly if you pass in pathnames 
that contain embedded spaces, but they're perfectly happy to use a symbolic link 
to the same files, as they use whatever name you pass in and don't try to 
resolve symbolic links.  It's only the fixincl program that runs into trouble 
with the link.

Anyway, OK to check in now, or shall I wait for 4.5?

-Sandra

-------------- next part --------------
A non-text attachment was scrubbed...
Name: gcc.log
Type: text/x-log
Size: 131 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/gcc-patches/attachments/20090117/99207450/attachment.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: gcc.patch
Type: text/x-patch
Size: 876 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/gcc-patches/attachments/20090117/99207450/attachment-0001.bin>


More information about the Gcc-patches mailing list