[PATCH] handle /etc/hotplug.d/ only if the event comes from udevd

This commit is contained in:
kay.sievers@vrfy.org 2004-11-29 04:47:59 +01:00 committed by Greg KH
parent 2af003feb2
commit 927bda3792

4
udev.c
View File

@ -61,6 +61,10 @@ static int manage_hotplug_event(void) {
int fd;
int len;
/* false, if we are called directly */
if (!getenv("MANAGED_EVENT"))
goto exit;
fd = open("/proc/sys/kernel/hotplug", O_RDONLY);
if (fd < 0)
goto exit;