mirror of
https://github.com/CalcProgrammer1/OpenRGB.git
synced 2026-10-23 17:08:58 -04:00
Start server before detecting devices
This commit is contained in:
1 parent
c71cc4f18a
commit
93dd7f2122
1 file changed
+16
-16
+16
-16
@@ -1780,6 +1780,22 @@ void ResourceManager::InitCoroutine()
|
||||
}
|
||||
}
|
||||
|
||||
/*-----------------------------------------------------*\
|
||||
| Start server if requested |
|
||||
\*-----------------------------------------------------*/
|
||||
if(start_server)
|
||||
{
|
||||
detection_percent = 0;
|
||||
detection_string = "Starting server";
|
||||
DetectionProgressChanged();
|
||||
|
||||
GetServer()->StartServer();
|
||||
if(!GetServer()->GetOnline())
|
||||
{
|
||||
LOG_DEBUG("[ResourceManager] Server failed to start");
|
||||
}
|
||||
}
|
||||
|
||||
/*-----------------------------------------------------*\
|
||||
| Perform actual detection if enabled |
|
||||
| Done in the same thread (InitThread), as we need to |
|
||||
@@ -1802,22 +1818,6 @@ void ResourceManager::InitCoroutine()
|
||||
ProcessPostDetection();
|
||||
}
|
||||
|
||||
/*-----------------------------------------------------*\
|
||||
| Start server if requested |
|
||||
\*-----------------------------------------------------*/
|
||||
if(start_server)
|
||||
{
|
||||
detection_percent = 100;
|
||||
detection_string = "Starting server";
|
||||
DetectionProgressChanged();
|
||||
|
||||
GetServer()->StartServer();
|
||||
if(!GetServer()->GetOnline())
|
||||
{
|
||||
LOG_DEBUG("[ResourceManager] Server failed to start");
|
||||
}
|
||||
}
|
||||
|
||||
/*-----------------------------------------------------*\
|
||||
| Process command line arguments after detection only |
|
||||
| if the pre-detection parsing indicated it should be |
|
||||
|
||||
Reference in new issue
Block a user