From 7ffaaf66a747fff1c861728cc996e775583f1760 Mon Sep 17 00:00:00 2001 From: Wim Taymans Date: Thu, 15 Feb 2018 10:47:43 +0100 Subject: [PATCH] v4l2: remove source on errors --- spa/plugins/v4l2/v4l2-utils.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/spa/plugins/v4l2/v4l2-utils.c b/spa/plugins/v4l2/v4l2-utils.c index 3ce94b4cc..a23609db0 100644 --- a/spa/plugins/v4l2/v4l2-utils.c +++ b/spa/plugins/v4l2/v4l2-utils.c @@ -1187,7 +1187,9 @@ static void v4l2_on_fd_events(struct spa_source *source) struct impl *this = source->data; if (source->rmask & SPA_IO_ERR) { - spa_log_warn(this->log, "v4l2 %p: error %d", this, source->rmask); + struct port *port = &this->out_ports[0]; + spa_log_error(this->log, "v4l2 %p: error %d", this, source->rmask); + spa_loop_remove_source(port->data_loop, &port->source); return; }