From ea2b4bcc7f803076116f3b937baae57fd943e17c Mon Sep 17 00:00:00 2001 From: titiger Date: Thu, 25 Sep 2014 23:50:37 +0200 Subject: [PATCH] Headless servers should not precalculate CRCs. This creates too much load when more than one server is running on the same machine. --- source/glest_game/main/main.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/source/glest_game/main/main.cpp b/source/glest_game/main/main.cpp index e885a58f..f30be482 100644 --- a/source/glest_game/main/main.cpp +++ b/source/glest_game/main/main.cpp @@ -5359,7 +5359,8 @@ int glestMain(int argc, char** argv) { bool startCRCPrecacheThread = config.getBool("PreCacheCRCThread","true"); //printf("### In [%s::%s Line: %d] precache thread enabled = %d SystemFlags::VERBOSE_MODE_ENABLED = %d\n",__FILE__,__FUNCTION__,__LINE__,startCRCPrecacheThread,SystemFlags::VERBOSE_MODE_ENABLED); if(SystemFlags::VERBOSE_MODE_ENABLED) printf("In [%s::%s Line: %d] precache thread enabled = %d\n",__FILE__,__FUNCTION__,__LINE__,startCRCPrecacheThread); - if(startCRCPrecacheThread == true) { + if (startCRCPrecacheThread == true + && GlobalStaticFlags::getIsNonGraphicalModeEnabled() == false) { static string mutexOwnerId = string(extractFileFromDirectoryPath(__FILE__).c_str()) + string("_") + intToStr(__LINE__); vector techDataPaths = config.getPathListForType(ptTechs);