plugins: handle some fd allocation errors

This commit is contained in:
Wim Taymans 2026-05-05 11:36:45 +02:00
parent 09dda9e4e0
commit 96594d6716
9 changed files with 20 additions and 0 deletions

View file

@ -906,6 +906,8 @@ impl_init(const struct spa_handle_factory *factory,
this->timer_source.data = this;
this->timer_source.fd = spa_system_timerfd_create(this->data_system, CLOCK_MONOTONIC,
SPA_FD_CLOEXEC | SPA_FD_NONBLOCK);
if (this->timer_source.fd < 0)
return this->timer_source.fd;
this->timer_source.mask = SPA_IO_IN;
this->timer_source.rmask = 0;