[Top][All Lists]

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

Re: quotearg.c's shell_quoting_style and MinGW

From: Paul Eggert
Subject: Re: quotearg.c's shell_quoting_style and MinGW
Date: Sun, 06 May 2012 10:13:13 -0700
User-agent: Mozilla/5.0 (X11; Linux i686; rv:12.0) Gecko/20120430 Thunderbird/12.0.1

On 05/06/2012 09:52 AM, Eli Zaretskii wrote:
But since 'diff' output can be fed to a shell or to another program,

It's a judgment call, but in this particular case the output of
diff is intended more for the user than for other programs, and
there is a good argument for consistency in output format regardless
of platform.

There was never such an implementation of popen on any non-Posix
platform (nor can there be, at least on Windows, because of the need
to support native file names with backslashes).

The idea here is not to reimplement popen from scratch in gnulib,
or to have gnulib popen support every feature that POSIX requires.
The idea is only to have a popen wrapper that works assuming that
its argument is quoted for the POSIX shell, using quotearg.
Such arguments have a simple format that can easily be converted
to mingw shell format.  Once this simple conversion is done, the
wrapper call the real mingw popen.

This should work with file names that contain backslashes, just
as it'd work for any other character.

reply via email to

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