diff options
author | Kay Sievers <kay.sievers@vrfy.org> | 2008-10-16 18:56:19 +0200 |
---|---|---|
committer | Kay Sievers <kay.sievers@vrfy.org> | 2008-10-16 18:56:19 +0200 |
commit | 3361a0f1105a2fe6000800431e8ef15293b41673 (patch) | |
tree | c0136b6b80c23f1ba84d3999d44716a65dbaa41a | |
parent | 3fb629fd5e3e90e04dc6f6e07998a277f0515a32 (diff) |
libudev: monitor - export MAJOR/MINOR only if available
-rw-r--r-- | udev/lib/libudev-monitor.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/udev/lib/libudev-monitor.c b/udev/lib/libudev-monitor.c index 382fbfac5f..d0f28849aa 100644 --- a/udev/lib/libudev-monitor.c +++ b/udev/lib/libudev-monitor.c @@ -367,7 +367,8 @@ struct udev_device *udev_monitor_receive_device(struct udev_monitor *udev_monito udev_device_unref(udev_device); return NULL; } - udev_device_set_devnum(udev_device, makedev(maj, min)); + if (maj > 0) + udev_device_set_devnum(udev_device, makedev(maj, min)); udev_device_set_info_loaded(udev_device); return udev_device; } |