From: Yu Watanabe Date: Sun, 12 Sep 2021 06:47:08 +0000 (+0900) Subject: sd-device: do not recreate the same symlinks which store watch handle X-Git-Tag: v250-rc1~686^2~1 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=20ec7d9ed53bb4820f4001e3527e0a966d3bcbec;p=thirdparty%2Fsystemd.git sd-device: do not recreate the same symlinks which store watch handle --- diff --git a/src/libsystemd/sd-device/device-private.c b/src/libsystemd/sd-device/device-private.c index 16a2e9e1e43..37eda23a5f6 100644 --- a/src/libsystemd/sd-device/device-private.c +++ b/src/libsystemd/sd-device/device-private.c @@ -680,7 +680,7 @@ int device_set_watch_handle(sd_device *device, int wd) { assert(device); - if (wd >= 0 && wd == device->watch_handle) + if (wd >= 0 && wd == device_get_watch_handle(device)) return 0; device_remove_watch_handle(device);