From fa505c588f041750b1429cf166ee0096e3ae19ca Mon Sep 17 00:00:00 2001 From: Leandro Ribeiro Date: Thu, 26 Dec 2019 16:41:09 -0300 Subject: [PATCH] content-protection: stop direct accessing core struct member Commit "weston-log: add function to avoid direct access to compositor members in non-core code" added the function weston_compositor_add_log_scope mainly to allow libweston users to avoid direct accessing core structs, as weston_compositor. Replace weston_log_context_add_log_scope usage by weston_compositor_add_log_scope. Signed-off-by: Leandro Ribeiro --- libweston/content-protection.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/libweston/content-protection.c b/libweston/content-protection.c index 5659a32b..625d3567 100644 --- a/libweston/content-protection.c +++ b/libweston/content-protection.c @@ -340,9 +340,8 @@ weston_compositor_enable_content_protection(struct weston_compositor *compositor cp->destroy_listener.notify = cp_destroy_listener; wl_signal_add(&compositor->destroy_signal, &cp->destroy_listener); - cp->debug = weston_log_ctx_add_log_scope(compositor->weston_log_ctx, - "content-protection-debug", - "debug-logs for content-protection", - NULL, NULL, NULL); + cp->debug = weston_compositor_add_log_scope(compositor, "content-protection-debug", + "debug-logs for content-protection", + NULL, NULL, NULL); return 0; }