mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-11-05 13:30:02 -05:00
pulse-server: validate subscription mask
This commit is contained in:
parent
514f138ec3
commit
3bd40f976f
1 changed files with 3 additions and 0 deletions
|
|
@ -946,6 +946,9 @@ static int do_subscribe(struct client *client, uint32_t command, uint32_t tag, s
|
||||||
pw_log_info("[%s] SUBSCRIBE tag:%u mask:%08x",
|
pw_log_info("[%s] SUBSCRIBE tag:%u mask:%08x",
|
||||||
client->name, tag, mask);
|
client->name, tag, mask);
|
||||||
|
|
||||||
|
if (mask & ~SUBSCRIPTION_MASK_ALL)
|
||||||
|
return -EINVAL;
|
||||||
|
|
||||||
client->subscribed = mask;
|
client->subscribed = mask;
|
||||||
|
|
||||||
return reply_simple_ack(client, tag);
|
return reply_simple_ack(client, tag);
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue