diff --git a/3rdparty/libnstd b/3rdparty/libnstd index 8de6982..1122d29 160000 --- a/3rdparty/libnstd +++ b/3rdparty/libnstd @@ -1 +1 @@ -Subproject commit 8de69820a7264bd7575683ead1306bd388a62970 +Subproject commit 1122d298db94349a649aae983c80f255f7a96308 diff --git a/src/Worker.cpp b/src/Worker.cpp index 0acf371..20502d2 100644 --- a/src/Worker.cpp +++ b/src/Worker.cpp @@ -291,14 +291,12 @@ namespace { UpdateResult updateRepository(const String& repoUrl, const String& askpassPath, const String& cacheDir, const String& auth) { - Map envs; String username; String password; - if (!auth.isEmpty()) decodeAuth(auth, username, password); - envs = Process::getEnvironmentVariables(); + Map envs = Process::getEnvironmentVariables(); envs.insert("GIT_ASKPASS", askpassPath); envs.insert("GCHSD_USERNAME", username); envs.insert("GCHSD_PASSWORD", password); @@ -320,7 +318,7 @@ namespace { process.join(exitCode); if (exitCode != 0) { - if (stdout.find("Authentication failed ")) + if (stdout.find(" Authentication failed ")) return UpdateResult::AuthFailure; command = String("git clone --quiet --mirror \"") + repoUrl + "\" \"" + cacheDir + "\""; @@ -331,12 +329,11 @@ namespace { Log::errorf("Could not launch command '%s': %s", (const char*)command, (const char*)Error::getErrorString()); return UpdateResult::Error; } - String stdout = readAllStdError(process); - uint32 exitCode = 1; + stdout = readAllStdError(process); process.join(exitCode); if (exitCode != 0) { - if (stdout.find("Authentication failed ")) + if (stdout.find(" Authentication failed ")) return UpdateResult::AuthFailure; return UpdateResult::Error; }