mirror of
https://github.com/moonlight-stream/moonlight-ios.git
synced 2026-04-07 08:26:18 +00:00
Fix memory leak in failure path
This commit is contained in:
@@ -23,6 +23,7 @@ static const int ports[numPorts] = {7, 9, 47998, 47999, 48000};
|
||||
CFDataRef dataPayload = CFDataCreate(kCFAllocatorDefault, [wolPayload bytes], [wolPayload length]);
|
||||
CFSocketRef wolSocket = CFSocketCreate(kCFAllocatorDefault, PF_INET, SOCK_DGRAM, IPPROTO_UDP, 0, NULL, NULL);
|
||||
if (!wolSocket) {
|
||||
CFRelease(dataPayload);
|
||||
NSLog(@"Failed to create WOL socket");
|
||||
return;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user