Skip to content

avoid direct acess to opaque struct

Leandro Ribeiro requested to merge leandrohrb/weston:compositor_log_scope into master

As mentioned by @pq in #328 (closed), it's not ideal to access core struct members in non-core code. One long-term goal is to make core structs opaque.

This is happening with the function weston_log_context_add_log_scope(), since it's necessary to access weston_compositor::weston_log_ctx and give as argument in the function call.

This adds the function weston_compositor_add_log_scope() and replace the usage of weston_log_context_add_log_scope() in non-core code.

Depends on MR !347 (merged)

Edited by Leandro Ribeiro

Merge request reports