DirectLink: prevent startup when the platform doesn't support multithreading.

#jira UE-161917, UE-159209
#rb none
#preflight 630757b7a45b007ea2d6a775

[CL 21561769 by Johan Duparc in ue5-main branch]
This commit is contained in:
Johan Duparc
2022-08-25 07:10:38 -04:00
parent d38f37d548
commit 674e1dbc6c
@@ -158,6 +158,12 @@ FEndpoint::FEndpoint(const FString& InName)
, InternalPtr(MakeUnique<FInternalThreadState>(*this, SharedState))
, Internal(*InternalPtr)
{
if (!FPlatformProcess::SupportsMultithreading())
{
UE_LOG(LogDirectLinkNet, Error, TEXT("Endpoint '%s': Unable to start endpoint: support for threads is required for DirectLink."), *SharedState.NiceName);
return;
}
ECommunicationStatus ComStatus = ValidateCommunicationStatus();
if (ComStatus != ECommunicationStatus::NoIssue)
{