From: kay.sievers@vrfy.org Date: Sun, 10 Apr 2005 19:15:12 +0000 (+0200) Subject: [PATCH] apply default permissions only for devices that will need it X-Git-Tag: 057~5 X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=1bbff4f03584dc0ba830d8cb0fc91d10bd79ac94;p=systemd [PATCH] apply default permissions only for devices that will need it --- diff --git a/udev_utils.c b/udev_utils.c index 5cdfb142..74b55ed4 100644 --- a/udev_utils.c +++ b/udev_utils.c @@ -89,9 +89,11 @@ int udev_init_device(struct udevice *udev, const char* devpath, const char *subs } } - udev->mode = 0660; - strcpy(udev->owner, "root"); - strcpy(udev->group, "root"); + if (udev->type == DEV_BLOCK || udev->type == DEV_CLASS) { + udev->mode = 0660; + strcpy(udev->owner, "root"); + strcpy(udev->group, "root"); + } return 0; }