diff --git a/src/uterm_monitor.c b/src/uterm_monitor.c index 3f9762c..b95082d 100644 --- a/src/uterm_monitor.c +++ b/src/uterm_monitor.c @@ -530,7 +530,7 @@ static void monitor_udev_change(struct uterm_monitor *mon, /* DRM devices send hotplug events; catch them here */ val = udev_device_get_property_value(dev, "HOTPLUG"); - if (!strcmp(val, "1")) { + if (val && !strcmp(val, "1")) { memset(&ev, 0, sizeof(ev)); ev.type = UTERM_MONITOR_HOTPLUG_DEV; ev.seat = sdev->seat;