[systemd-commits] src/libudev
Kay Sievers
kay at kemper.freedesktop.org
Fri Dec 14 06:37:37 PST 2012
src/libudev/libudev-enumerate.c | 2 ++
1 file changed, 2 insertions(+)
New commits:
commit e68893075083a7461b1572233d23fdb23541d630
Author: Michael Terry <michael.terry at canonical.com>
Date: Fri Dec 14 09:02:13 2012 -0500
libudev: validate 'udev' argument to udev_enumerate_new()
https://bugs.freedesktop.org/show_bug.cgi?id=58289
diff --git a/src/libudev/libudev-enumerate.c b/src/libudev/libudev-enumerate.c
index 1729655..6a5f4e0 100644
--- a/src/libudev/libudev-enumerate.c
+++ b/src/libudev/libudev-enumerate.c
@@ -81,6 +81,8 @@ _public_ struct udev_enumerate *udev_enumerate_new(struct udev *udev)
{
struct udev_enumerate *udev_enumerate;
+ if (udev == NULL)
+ return NULL;
udev_enumerate = calloc(1, sizeof(struct udev_enumerate));
if (udev_enumerate == NULL)
return NULL;
More information about the systemd-commits
mailing list