diff options
author | greg@kroah.com <greg@kroah.com> | 2004-11-10 18:11:00 -0800 |
---|---|---|
committer | Greg KH <gregkh@suse.de> | 2005-04-26 22:09:26 -0700 |
commit | 800ab95bd55c9beebd14fd23ef34ea7f3e055e6a (patch) | |
tree | 8cce4165f20ec761e783df5fce410386178e3b6b /test/udev-test.pl | |
parent | 52a6ef66f2e98491b40b176619035abca3777a2c (diff) |
[PATCH] make udev-test.pl test for root permissions before running
Should prevent false error reports from happening.
Diffstat (limited to 'test/udev-test.pl')
-rw-r--r-- | test/udev-test.pl | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/test/udev-test.pl b/test/udev-test.pl index e615a1eda8..e8ce0b44dd 100644 --- a/test/udev-test.pl +++ b/test/udev-test.pl @@ -1275,6 +1275,13 @@ sub run_test { } +# only run if we have root permissions +# due to mknod restrictions +if (!($<==0)) { + print "Must have root permissions to run properly.\n"; + exit; +} + # prepare system("rm -rf $udev_root"); mkdir($udev_root) || die "unable to create udev_root: $udev_root\n"; |