]> git.ipfire.org Git - thirdparty/systemd.git/commit
udev-watch: do not try to remove invalid watch handle 36357/head
authorYu Watanabe <watanabe.yu+github@gmail.com>
Wed, 12 Feb 2025 00:23:33 +0000 (09:23 +0900)
committerYu Watanabe <watanabe.yu+github@gmail.com>
Wed, 12 Feb 2025 00:27:24 +0000 (09:27 +0900)
commitb3b442062045eac61a9dd3ed73b650dfb5be0b46
tree5b3d661d5e41df8172b09f21e9acadd90891f648
parenta52aad3b4bb735a22ce67110142d135819589a87
udev-watch: do not try to remove invalid watch handle

When a new device is processed, there should be no watch handle for
the device, hence udev_watch_clear() provides -1. Let's not try to call
inotify_rm_watch() in that case.

This should not change any behavior. Just for suppressing spurious
debugging log:
=====
(udev-worker)[3626140]: zram1: Removing watch handle -1.
=====
src/udev/udev-watch.c