Perform wildcard expansion in Process::GetArgumentVector on Windows (PR17098)
authorHans Wennborg <hans@hanshq.net>
Wed, 16 Jul 2014 00:52:11 +0000 (00:52 +0000)
committerHans Wennborg <hans@hanshq.net>
Wed, 16 Jul 2014 00:52:11 +0000 (00:52 +0000)
commit21f0f133948eea4010ea054b04dd5954eefeb767
tree06e769f83d53c67a05de4af4f8ec1d4760de9a9e
parent2c156f852c6e52772b06c6342c1b03a64e7f06e7
Perform wildcard expansion in Process::GetArgumentVector on Windows (PR17098)

On Windows, wildcard expansion isn't performed by the shell, but left to the
program itself. The common way to do this is to link with setargv.obj, which
performs the expansion on argc/argv before main is entered. However, we don't
use argv in Clang on Windows, but instead call GetCommandLineW so we can handle
unicode arguments. This means we have to do wildcard expansion ourselves.

A test case will be added on the Clang side.

Differential Revision: http://reviews.llvm.org/D4529

llvm-svn: 213114
llvm/lib/Support/Windows/Process.inc