This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: PATCH: PowerPC simulator doesn't handle spaces in filenames
- From: Daniel Jacobowitz <drow at false dot org>
- To: Mark Mitchell <mark at codesourcery dot com>
- Cc: gdb-patches at sources dot redhat dot com
- Date: Tue, 24 Jan 2006 16:24:44 -0500
- Subject: Re: PATCH: PowerPC simulator doesn't handle spaces in filenames
- References: <200601240559.k0O5xhER007274@sethra.codesourcery.com>
On Mon, Jan 23, 2006 at 09:59:43PM -0800, Mark Mitchell wrote:
>
> The PowerPC simulator simulates bits of openprom functionality. In
> particular, it feeds the program file name into the openprom device
> tree. However, filenames containing a space or backslash (both of
> which are very common on Windows, but can also occur on UNIX), were
> not quoted. (Here, quoting means enclosing the entire filename in
> double-quotes, and protecting backslashes by double-quoting them.)
>
> Tested by verifying that I could run a PowerPC program with a space
> and/or backslash in its name, on both x86_64-unknown-linux-gnu and
> i686-mingw32.
>
> OK?
You've escaped backslashes, but what about double quotes? I assume
this eventually goes to parse_string_property. It's not immediately
obvious, but the unescaping loop there will unescape both backslashes
and double quotes (see print_string).
--
Daniel Jacobowitz
CodeSourcery