mirror of
https://github.com/OpenRCT2/OpenRCT2
synced 2026-01-15 19:13:07 +01:00
Initialize result pointer
This fixes a crash in case getaddrinfo returns an error.
This commit is contained in:
committed by
Michał Janiszewski
parent
b89e01de8b
commit
0bb0c3b60f
@@ -449,7 +449,7 @@ private:
|
||||
hints.ai_flags = AI_PASSIVE;
|
||||
}
|
||||
|
||||
addrinfo * result;
|
||||
addrinfo * result = nullptr;
|
||||
getaddrinfo(address, serviceName.c_str(), &hints, &result);
|
||||
if (result == nullptr)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user