MCPcopy Create free account
hub / github.com/ammaarreshi/Generals-Mac-iOS-iPad / StartPatchCheck

Function StartPatchCheck

Core/Tools/PATCHGET/CHATAPI.cpp:446–470  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

444///////////////////////////////////////////////////////////////////////////////////////
445
446static void StartPatchCheck( void )
447{
448 checkingForPatch = true;
449 std::string gameURL, mapURL;
450 std::string configURL, motdURL;
451
452 FormatURLFromRegistry(gameURL, mapURL, configURL, motdURL);
453
454 std::string proxy;
455 if (GetStringFromRegistry("", "Proxy", proxy))
456 {
457 if (!proxy.empty())
458 {
459 ghttpSetProxy(proxy.c_str());
460 }
461 }
462
463 // check for a patch first
464 checksLeft = 2;
465 cantConnect = false;
466 ghttpGet(gameURL.c_str(), GHTTPFalse, patchCheckCallback, nullptr);
467 ghttpGet(mapURL.c_str(), GHTTPFalse, patchCheckCallback, nullptr);
468
469 DEBUG_LOG(("Started looking for patches at '%s' && '%s'", gameURL.c_str(), mapURL.c_str()));
470}
471
472///////////////////////////////////////////////////////////////////////////////////////
473

Callers 3

Update_If_RequiredFunction · 0.70
MainMenuSystemFunction · 0.50
MainMenuSystemFunction · 0.50

Calls 4

FormatURLFromRegistryFunction · 0.85
emptyMethod · 0.80
c_strMethod · 0.80
GetStringFromRegistryFunction · 0.70

Tested by

no test coverage detected