Skip to content

Commit

Permalink
Windows: fix MSVC compilations at HEAD
Browse files Browse the repository at this point in the history
Strip quotes from arg0 in call_python.bat .
This bug was has been there longer, but never got
triggered, because we only quoted arg0 if it
contained spaces, which it most likely never
actually did, or not in this particular case.

After submitting e68c6b5 and 9e8bc63 which fixed
the compilation errors in the former, we started
always quoting argv0 in subprocesses, which
exposed this bug, leading to a corrupt DRIVER_DIR
value in call_python.bat.

Fixes #2402

--
Change-Id: Iab5c00001fc4307f2e23c46c8187f5ef15d83d41
Reviewed-on: https://cr.bazel.build/8436
PiperOrigin-RevId: 145310121
MOS_MIGRATED_REVID=145310121
  • Loading branch information
laszlocsomor authored and katre committed Jan 23, 2017
1 parent ca43c87 commit 4e267c8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tools/cpp/wrapper/bin/call_python.bat.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@

:: Invoke the python script under pydir with the same basename
@echo OFF
set arg0=%1
set arg0=%~1
for %%F in ("%arg0%") do set DRIVER_BIN=%%~dpF

for /F %%i in ("%arg0%") do set TOOLNAME=%%~ni
Expand Down

0 comments on commit 4e267c8

Please sign in to comment.