1
0
mirror of https://github.com/Ylianst/MeshAgent synced 2025-12-15 15:53:55 +00:00

Updated self-update on windows to use & instead of &&

This commit is contained in:
Bryan Roe
2021-01-16 13:18:02 -08:00
parent baa34ebbbf
commit 22f43bdad4

View File

@@ -2622,7 +2622,7 @@ void MeshServer_selfupdate_continue(MeshAgentHostContainer *agent)
ILibUTF8ToWideEx(agent->exePath, (int)strnlen_s(agent->exePath, 4096), w_exepath, 4096);
swprintf_s(cmd, MAX_PATH, L"%s\\system32\\cmd.exe", env);
swprintf_s(parms, 65535, L"/C wmic service \"%s\" call stopservice && copy \"%s\" \"%s\" && wmic service \"%s\" call startservice && erase \"%s\"",
swprintf_s(parms, 65535, L"/C wmic service \"%s\" call stopservice & copy \"%s\" \"%s\" & wmic service \"%s\" call startservice & erase \"%s\"",
w_meshservicename, w_updatefile, w_exepath, w_meshservicename, w_updatefile);
ILIBLOGMESSAGEX("SelfUpdate -> Updating and restarting service...");