rtmp-services: Don't show "service not found" if name empty

Fixes an issue where the log could have "Could not find service" with an
empty service name when opening properties.
This commit is contained in:
jp9000 2017-10-15 05:26:11 -07:00
parent a76b919c6e
commit 48a5f0e51a

View File

@ -467,9 +467,10 @@ static void initialize_output(struct rtmp_common *service, json_t *root,
json_t *recommended;
if (!json_service) {
blog(LOG_WARNING, "rtmp-common.c: [initialize_output] "
"Could not find service '%s'",
service->service);
if (service->service && *service->service)
blog(LOG_WARNING, "rtmp-common.c: [initialize_output] "
"Could not find service '%s'",
service->service);
return;
}