Merge pull request #1479 from hgy59/fix_mdns_avahi_init

mdns_init: improve error handling (avoid null reference access)
This commit is contained in:
ejurgensen
2022-05-22 12:14:06 -07:00
committed by GitHub

View File

@@ -1044,7 +1044,7 @@ mdns_init(void)
client_callback, NULL, &error); client_callback, NULL, &error);
if (!mdns_client) if (!mdns_client)
{ {
DPRINTF(E_WARN, L_MDNS, "mdns_init: Could not create Avahi client: %s\n", MDNSERR); DPRINTF(E_WARN, L_MDNS, "mdns_init: Could not create Avahi client: %s\n", avahi_strerror(error));
return -1; return -1;
} }