-
This patch fixes cases, where the range is full, some ports fail with HOST_CANDIDATE_CANT_CREATE_SOCKET, other fail with HOST_CANDIDATE_DUPLICATE_PORT, the value of res we keep when leaving the loop is randomly the one of the last iteration of the loop. CANT_CREATE_SOCKET still happens when trying to create an udp bsd socket with the same address and port than one of another component, so it is also a case of duplicate port in fact. To be homogeneous, we add a gerror for nice_udp_bsd_socket_new(), like we did in nice_tcp_passive_socket_new(), and we can catch the same G_IO_ERROR_ADDRESS_IN_USE there too, when failing to get free available udp ports. This patch is a complement to merge request !158
7ec7f66d