浏览代码

Fix bug for when no multithreaded config is given

Joseph Henry 10 月之前
父节点
当前提交
e42848d37d
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      service/OneService.cpp

+ 1 - 1
service/OneService.cpp

@@ -2653,7 +2653,7 @@ public:
 		_portMappingEnabled = OSUtils::jsonBool(settings["portMappingEnabled"],true);
 #if defined(__LINUX__) || defined(__FreeBSD__)
 		_multicoreEnabled = OSUtils::jsonBool(settings["multicoreEnabled"],false);
-		_concurrency = OSUtils::jsonInt(settings["concurrency"],0);
+		_concurrency = OSUtils::jsonInt(settings["concurrency"],1);
 		_cpuPinningEnabled = OSUtils::jsonBool(settings["cpuPinningEnabled"],false);
 		if (_multicoreEnabled) {
 			unsigned int maxConcurrency = std::thread::hardware_concurrency();