iOS Failed to find a session with OnlineSubSystemNull

Hi,

I have a server (a PC) and companions app. Connections with OnlineSubsystemNull work perfectly with Android but not at all with iOS.

I do that: IOS SocketSubsystem reports back wrong host IP to have a correct socket and broadcast packets. But iOS find nothing with the FindSessions.

With WireShark there are the same packets for android and ios.

  • IPAdd of the companion app broadcast on port 14001
  • IPAdd of the server broadcast on port 14001

But iOS never get the server’s packet.

In FLanBeacon::ReceivePacket(uint8 PacketData, int32 BufferSize)*,
the function *ListenSocket->RecvFrom(PacketData, BufferSize, BytesRead, SockAddr); has always BytesRead at 0 but have no error and the request end with a timeout in FOnlineSessionNull::OnLANSearchTimeout().

Do you have any idea?

Thank you in advance.

I found a solution, i’ll make a pull request:

In the function FSocketSubsystemIOS::GetLocalHostAddr(FoutputDevice& Out, bool& bCanBinAll)

After bool bWasCellSet = false; add:
bCanBindAll = false;

And after
WifiAddress = ((sockaddr_in)Travel->ifa_addr)->sin_addr.s_addr;*

bWasWifiSet = true;

add
bCanBindAll = true;

I hope that can help!