perm: add permission mask to global

Add a mask of possible permissions for a global.
Make sure the permissions of an object are limited to the global
mask.
This commit is contained in:
Wim Taymans 2023-07-26 18:43:15 +02:00
parent 9bcc90fdc3
commit 212fe59530
34 changed files with 53 additions and 5 deletions

View file

@ -292,6 +292,7 @@ int endpoint_stream_init(struct endpoint_stream *this,
this->global = pw_global_new (context,
PW_TYPE_INTERFACE_EndpointStream,
PW_VERSION_ENDPOINT_STREAM,
PW_ENDPOINT_STREAM_PERM_MASK,
properties, endpoint_stream_bind, this);
if (!this->global)
goto no_mem;

View file

@ -322,6 +322,7 @@ int endpoint_init(struct endpoint *this,
this->global = pw_global_new (context,
PW_TYPE_INTERFACE_Endpoint,
PW_VERSION_ENDPOINT,
PW_ENDPOINT_PERM_MASK,
NULL, endpoint_bind, this);
if (!this->global)
goto no_mem;