[igt-dev] [PATCH i-g-t 1/4] lib/igt_device_scan: Add missing Check for return value in scan_drm_devices

Arkadiusz Hiler
2020-05-26T12:24:36Z

From: Ayaz A Siddiqui <ayaz.siddiqui@intel.com>

Return value of udev_enumerate_add_match_property() was not being checked
in scan_drm_devices().

Signed-off-by: Ayaz A Siddiqui <ayaz.siddiqui@intel.com>
Signed-off-by: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
---
lib/igt_device_scan.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lib/igt_device_scan.c b/lib/igt_device_scan.c
index 601d6fb0..7b0fc00e 100644
--- a/lib/igt_device_scan.c
+++ b/lib/igt_device_scan.c
@@ -532,7 +532,7 @@ static void scan_drm_devices(void)
ret = udev_enumerate_add_match_subsystem(enumerate, "drm");
igt_assert(!ret);

- udev_enumerate_add_match_property(enumerate, "DEVNAME", "/dev/dri/*");
+ ret = udev_enumerate_add_match_property(enumerate, "DEVNAME", "/dev/dri/*");
igt_assert(!ret);

ret = udev_enumerate_scan_devices(enumerate);
--
2.25.4