avahi: tvheadend_webroot can be NULL - fix the fix
This commit is contained in:
parent
5c170675da
commit
6a5b012dc3
1 changed files with 2 additions and 3 deletions
|
@ -152,7 +152,7 @@ create_services(AvahiClient *c)
|
|||
path = malloc(strlen(tvheadend_webroot) + 6);
|
||||
sprintf(path, "path=%s", tvheadend_webroot);
|
||||
} else {
|
||||
path = "/";
|
||||
path = strdup("path=/");
|
||||
}
|
||||
|
||||
/* Add the service for HTTP */
|
||||
|
@ -162,8 +162,7 @@ create_services(AvahiClient *c)
|
|||
path,
|
||||
NULL)) < 0) {
|
||||
|
||||
if (tvheadend_webroot)
|
||||
free(path);
|
||||
free(path);
|
||||
|
||||
if (ret == AVAHI_ERR_COLLISION)
|
||||
goto collision;
|
||||
|
|
Loading…
Add table
Reference in a new issue