Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2299)

Unified Diff: bootstrap/win/win_tools.bat

Issue 1848153002: Escape slashes in paths in windows tool bootstrapping. (Closed) Base URL: https://chromium.googlesource.com/chromium/tools/depot_tools.git@master
Patch Set: Created 4 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: bootstrap/win/win_tools.bat
diff --git a/bootstrap/win/win_tools.bat b/bootstrap/win/win_tools.bat
index 6b6901820698110259d1e1d04a28bb169ae0b27c..ae9ccef09ddda603d007508c4db4cf92191eaa6e 100644
--- a/bootstrap/win/win_tools.bat
+++ b/bootstrap/win/win_tools.bat
@@ -114,7 +114,11 @@ if exist "%GIT_INST_DIR%\." rd /q /s "%GIT_INST_DIR%"
:: -sd1 : Self delete SFX archive
:: -InstallPath : Where to put the files
:: -Directory : Run the post-extract program with this current-working-directory
-call "%GIT_DOWNLOAD_PATH%" -y -sd1 -InstallPath="%GIT_INST_DIR%" -Directory="%GIT_INST_DIR%"
+::
+:: Path slashes must be escaped or the 7zip sfx treats e.g. path\to\dir as
+:: path[tab]o\dir.
+set GIT_INST_DIR_ESC=%GIT_INST_DIR:\=\\%
+call "%GIT_DOWNLOAD_PATH%" -y -sd1 -InstallPath="%GIT_INST_DIR_ESC%" -Directory="%GIT_INST_DIR_ESC%"
if errorlevel 1 goto :GIT_FAIL
del "%GIT_DOWNLOAD_PATH%"
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698