g_socket_join_multicast_group won't fail if specify a non-exists iface
Submitted by cee1
Link to original bug (#705547)
Description
g_socket_join_multicast_group() -> g_socket_multicast_group_operation()
#ifdef HAVE_IP_MREQN if (iface) mc_req.imr_ifindex = if_nametoindex (iface); else mc_req.imr_ifindex = 0; /* Pick any. */ #endif
For if_nametoindex(http://msdn.microsoft.com/en-us/library/windows/desktop/bb408409(v=vs.85).aspx, http://linux.die.net/man/3/if_nametoindex), it will return 0 on error, hence, g_socket_join_multicast_group will pick any iface available instead of returning failure, if passed a non-exists iface.