From: Marius Vlad Date: Tue, 5 Nov 2019 15:08:17 +0000 (+0200) Subject: weston-log: Avoid prefix-matching the scope name when checking for a X-Git-Tag: upstream/9.0.0~308 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=f68ee07880733134e6cfd4953dc49ee9d61301fe;p=platform%2Fupstream%2Fweston.git weston-log: Avoid prefix-matching the scope name when checking for a pending subscription It limits to scope name to an exact match. Signed-off-by: Marius Vlad Reported-by: Pekka Paalanen --- diff --git a/libweston/weston-log.c b/libweston/weston-log.c index 9415f053..b2c4597c 100644 --- a/libweston/weston-log.c +++ b/libweston/weston-log.c @@ -124,7 +124,7 @@ find_pending_subscription(struct weston_log_context *log_ctx, struct weston_log_subscription *sub; wl_list_for_each(sub, &log_ctx->pending_subscription_list, source_link) - if (!strncmp(sub->scope_name, scope_name, strlen(scope_name))) + if (!strcmp(sub->scope_name, scope_name)) return sub; return NULL;