mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-11-02 09:01:50 -05:00
support: also protect against recursive invocations
Add an extra private field to the source to store the pollevent of the current iteration. This changes ABI but it seems an embedded source is not used outside of our own plugins and the unit test doesn't test this ABI case. Whenever a source is removed, we can set the data field of the pollevent to NULL so that it won't be handled in any iteration anymore. Avoid dispatching the same event multiple times when doing recursive iterations. Add some more unit tests for this. Fixes #2114
This commit is contained in:
parent
9acae229ab
commit
bf886ba209
3 changed files with 151 additions and 16 deletions
|
|
@ -66,6 +66,8 @@ struct spa_source {
|
|||
int fd;
|
||||
uint32_t mask;
|
||||
uint32_t rmask;
|
||||
/* private data for the loop implementer */
|
||||
void *priv;
|
||||
};
|
||||
|
||||
typedef int (*spa_invoke_func_t) (struct spa_loop *loop,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue