[mdns] Make connection test optional and only do it for Airplay (fixes #602)

Some remotes don't respond as expected to the test. Retune will give connection
refused, because the test is made too quickly, before the service is running.

Even if we delay the test it won't work because Retune crashes.

Since the false mdns advertisements are only seen on Airplay, we only do the
test there.
This commit is contained in:
ejurgensen
2018-10-14 22:10:28 +02:00
parent 07e46d75c8
commit df7456dc39
6 changed files with 25 additions and 21 deletions

View File

@@ -1774,7 +1774,7 @@ cast_init(void)
else
family = AF_INET;
ret = mdns_browse("_googlecast._tcp", family, cast_device_cb);
ret = mdns_browse("_googlecast._tcp", family, cast_device_cb, 0);
if (ret < 0)
{
DPRINTF(E_LOG, L_CAST, "Could not add mDNS browser for Chromecast devices\n");

View File

@@ -5025,7 +5025,7 @@ raop_init(void)
else
family = AF_INET;
ret = mdns_browse("_raop._tcp", family, raop_device_cb);
ret = mdns_browse("_raop._tcp", family, raop_device_cb, MDNS_CONNECTION_TEST);
if (ret < 0)
{
DPRINTF(E_LOG, L_RAOP, "Could not add mDNS browser for AirPlay devices\n");