Pārlūkot izejas kodu

Merge branch 'candidate-7.10.28' into candidate-7.10.x

Signed-off-by: Richard Chapman <rchapman@hpccsystems.com>
Richard Chapman 4 gadi atpakaļ
vecāks
revīzija
08e7e7268b
1 mainītis faili ar 6 papildinājumiem un 2 dzēšanām
  1. 6 2
      ecl/ecl-bundle/ecl-bundle.cpp

+ 6 - 2
ecl/ecl-bundle/ecl-bundle.cpp

@@ -379,9 +379,12 @@ public:
                 if (!path.length())
                     path.append(".");
                 if (bundleFile->isDirectory()==fileBool::foundYes && !directoryContainsBundleFile(bundleFile))
-                    includeOpt.appendf(" \"-I%s\"", bundle);
+                    includeOpt.appendf(" \"-I%s\"", cleanedParam.str());
                 else
+                {
+                    removeTrailingPathSepChar(path);  // Trailing \ does not play nice with quotes in Windows
                     includeOpt.appendf(" \"-I%s\"", path.str());
+                }
             }
             else
                 throw MakeStringException(0, "File not found");
@@ -1105,7 +1108,8 @@ protected:
                 fetchedLocation.append(tmp).append(PATHSEPCHAR);
                 splitFilename(url, NULL, NULL, &fetchedLocation, NULL);
                 StringBuffer output;
-                VStringBuffer params("clone --depth=1 %s %s", url, fetchedLocation.str());
+                removeTrailingPathSepChar(fetchedLocation);
+                VStringBuffer params("clone --depth=1 %s \"%s\"", url, fetchedLocation.str());
                 if (optBranch)
                     params.appendf(" -b %s", optBranch.str());
                 unsigned retCode = doPipeCommand(output, "git", params, NULL);