mirror of
https://github.com/libretro/RetroArch
synced 2025-01-30 21:32:45 +00:00
Fix lan rooms on android
This simple change makes lan discovery work on android again. The is_lan_address function was meant to filter out duplicate rooms only anyway and this change shouldn't harm anything The responses on android are seen as IPv6 mapped IPv4 addresses so this is needed for this to work anyway I/RetroArch: [Discovery] Responnse received on LAN interface ::ffff:192.168.1.241. I/RetroArch: [Netplay]: Connecting to ::ffff:192.168.1.241|55435 (deferred)
This commit is contained in:
parent
b8d9070c9b
commit
cf2ecf506c
@ -333,13 +333,17 @@ static bool netplay_lan_ad_client_response(void)
|
||||
|
||||
/* And that we know how to handle it */
|
||||
#ifdef HAVE_INET6
|
||||
#ifndef ANDROID
|
||||
if (their_addr.ss_family != AF_INET)
|
||||
continue;
|
||||
#endif
|
||||
|
||||
if (!netplay_is_lan_address(
|
||||
(struct sockaddr_in *) &their_addr))
|
||||
continue;
|
||||
#endif
|
||||
if (their_addr.ss_family != AF_INET)
|
||||
{
|
||||
if (!netplay_is_lan_address(
|
||||
(struct sockaddr_in *) &their_addr))
|
||||
continue;
|
||||
}
|
||||
|
||||
#ifndef HAVE_SOCKET_LEGACY
|
||||
if (getnameinfo((struct sockaddr *)
|
||||
|
Loading…
x
Reference in New Issue
Block a user