[Support] Treat null bytes as separator in windows command line strings
authorMartin Storsjo <martin@martin.st>
Fri, 14 Sep 2018 06:08:01 +0000 (06:08 +0000)
committerMartin Storsjo <martin@martin.st>
Fri, 14 Sep 2018 06:08:01 +0000 (06:08 +0000)
commitf08a9c700bcf1f7096a471ba521b030318582e4b
tree5b2b6a9b6a24d75128b8dcfbeb0d72210545ec87
parente385365c40fc6aa57341e804f7722ca41ca4df2b
[Support] Treat null bytes as separator in windows command line strings

When reading directives from a .drectve section, the directives are
tokenized as a normal windows command line. However in these cases,
link.exe allows the directives to be separated by null bytes, not only by
spaces.

A test case for this change will be added in the lld repo.

Differential Revision: https://reviews.llvm.org/D52014

llvm-svn: 342204
llvm/lib/Support/CommandLine.cpp