From 46f89d80095eb6ba0baf74dbfad82a863fa55d93 Mon Sep 17 00:00:00 2001 From: Hans de Goede Date: Wed, 7 Aug 2024 19:19:53 +0200 Subject: [PATCH] spa: v4l2: Remove start_watching_device() loop from start_inotify() Now that start_monitor() (which calls start_inotify()) is called before enum_devices() it no longer is necessary to call start_watching_device() for devices which have been enumerated before start_inotify() gets called (since there will not be any such devices anymore). Signed-off-by: Hans de Goede --- spa/plugins/v4l2/v4l2-udev.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/spa/plugins/v4l2/v4l2-udev.c b/spa/plugins/v4l2/v4l2-udev.c index 4c9c6cb5c..7118b6239 100644 --- a/spa/plugins/v4l2/v4l2-udev.c +++ b/spa/plugins/v4l2/v4l2-udev.c @@ -477,9 +477,6 @@ static int start_inotify(struct impl *this) spa_loop_add_source(this->main_loop, &this->notify); - for (size_t i = 0; i < this->n_devices; i++) - start_watching_device(this, &this->devices[i]); - return 0; }