From 5dd35c590e3768c0fb0796191ca52d3dd3871221 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lu=C3=ADs=20Faceira?= Date: Wed, 9 Dec 2015 18:18:39 +0000 Subject: [PATCH] Escaped git --reference argument --- src/Composer/Downloader/GitDownloader.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Composer/Downloader/GitDownloader.php b/src/Composer/Downloader/GitDownloader.php index c6767d2fe..261cdf3af 100644 --- a/src/Composer/Downloader/GitDownloader.php +++ b/src/Composer/Downloader/GitDownloader.php @@ -43,7 +43,7 @@ class GitDownloader extends VcsDownloader implements DvcsDownloaderInterface GitUtil::cleanEnv(); $path = $this->normalizePath($path); $cachePath = $this->config->get('cache-vcs-dir').'/'.preg_replace('{[^a-z0-9.]}i', '-', $url).'/'; - $cacheOptions = file_exists($cachePath) ? $cacheOptions = '--reference '.$cachePath.' ' : ''; + $cacheOptions = file_exists($cachePath) ? '--reference '.ProcessExecutor::escape($cachePath).' ' : ''; $ref = $package->getSourceReference(); $flag = Platform::isWindows() ? '/D ' : '';