From: Yu Watanabe Date: Mon, 27 Aug 2018 06:33:17 +0000 (+0900) Subject: sd-device: sd_device_enumerator_get_subsystem_next() requests the device list is... X-Git-Tag: v240~791^2 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=refs%2Fpull%2F9950%2Fhead;p=thirdparty%2Fsystemd.git sd-device: sd_device_enumerator_get_subsystem_next() requests the device list is uptodate --- diff --git a/src/libsystemd/sd-device/device-enumerator.c b/src/libsystemd/sd-device/device-enumerator.c index 9f7783e86cd..e1f60126b3a 100644 --- a/src/libsystemd/sd-device/device-enumerator.c +++ b/src/libsystemd/sd-device/device-enumerator.c @@ -935,7 +935,7 @@ _public_ sd_device *sd_device_enumerator_get_subsystem_first(sd_device_enumerato _public_ sd_device *sd_device_enumerator_get_subsystem_next(sd_device_enumerator *enumerator) { assert_return(enumerator, NULL); - if (enumerator->scan_uptodate || + if (!enumerator->scan_uptodate || enumerator->type != DEVICE_ENUMERATION_TYPE_SUBSYSTEMS) return NULL;