weston-log: rename confusing function names and parameters
As addressed by @pq in #328 (closed) and @daniels in !347 (comment 368667), we have some confusing names in weston-log:
-
1/4 - In the function
weston_compositor_add_log_scope()
we have astruct weston_log_context
parameter that in the .c file is named log_ctx. In the .h, the same parameter is named compositor. This is confusing, since its type is notstruct weston_compositor
, butstruct weston_log_context
. Rename the parameter to log_ctx in the .h. -
2/4 - Something similar happens in the function
weston_log_subscription_printf()
, where we have astruct weston_log_subscription
parameter that in the .c file is named sub. In the .h, the same parameter is named scope. This is confusing, since its type is notstruct weston_log_scope
, butstruct weston_log_subscription
. Rename the parameter to sub in the .h. -
3/4 - Also, the name
weston_compositor_add_log_scope()
is confusing as well, as it doesn't take astruct weston_compositor
argument. Rename the function toweston_log_ctx_add_log_scope()
. -
4/4 - The same happens for the function
weston_compositor_log_scope_destroy()
, that doesn't take astruct weston_compositor
argument. Rename the function toweston_log_scope_destroy()
.
Fixes: #328 (closed)