diff options
author | Ruslan Ermilov <ru@FreeBSD.org> | 2001-02-26 08:09:51 +0000 |
---|---|---|
committer | Ruslan Ermilov <ru@FreeBSD.org> | 2001-02-26 08:09:51 +0000 |
commit | f806cd425e5ec3a41370c8f23f42e3b4ef406365 (patch) | |
tree | 84f28d0e651572b0768a1cf5734c8effc68f93ad /sbin | |
parent | 87a636ccb0507e9461afb97e6650b74a6bb3601f (diff) | |
download | src-f806cd425e5ec3a41370c8f23f42e3b4ef406365.tar.gz src-f806cd425e5ec3a41370c8f23f42e3b4ef406365.zip |
Backout -a restriction hack.
Requested by: rwatson
Notes
Notes:
svn path=/head/; revision=73076
Diffstat (limited to 'sbin')
-rw-r--r-- | sbin/dmesg/dmesg.8 | 1 | ||||
-rw-r--r-- | sbin/dmesg/dmesg.c | 7 |
2 files changed, 1 insertions, 7 deletions
diff --git a/sbin/dmesg/dmesg.8 b/sbin/dmesg/dmesg.8 index 8d59634d35ae..196b4dc0be5a 100644 --- a/sbin/dmesg/dmesg.8 +++ b/sbin/dmesg/dmesg.8 @@ -54,7 +54,6 @@ Show all data in the message buffer. This includes any syslog records and .Pa /dev/console output. -Only root is allowed to use this option. .It Fl M Extract values associated with the name list from the specified core instead of the default diff --git a/sbin/dmesg/dmesg.c b/sbin/dmesg/dmesg.c index 3883688de3de..541e9dfb8c0f 100644 --- a/sbin/dmesg/dmesg.c +++ b/sbin/dmesg/dmesg.c @@ -45,7 +45,6 @@ static const char rcsid[] = "$FreeBSD$"; #endif /* not lint */ -#include <sys/types.h> #include <sys/msgbuf.h> #include <err.h> @@ -54,10 +53,9 @@ static const char rcsid[] = #include <locale.h> #include <stdio.h> #include <stdlib.h> -#include <sysexits.h> -#include <syslog.h> #include <unistd.h> #include <vis.h> +#include <sys/syslog.h> struct nlist nl[] = { #define X_MSGBUF 0 @@ -111,9 +109,6 @@ main(argc, argv) if (memf != NULL || nlistf != NULL) setgid(getgid()); - if (all && getuid()) - errx(EX_NOPERM, "must be root to use -a"); - /* Read in kernel message buffer, do sanity checks. */ if ((kd = kvm_open(nlistf, memf, NULL, O_RDONLY, "dmesg")) == NULL) exit (1); |