summaryrefslogtreecommitdiff
path: root/usr.sbin/trpt/trpt.c
diff options
context:
space:
mode:
Diffstat (limited to 'usr.sbin/trpt/trpt.c')
-rw-r--r--usr.sbin/trpt/trpt.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/usr.sbin/trpt/trpt.c b/usr.sbin/trpt/trpt.c
index 667f1aa4479..7f5769884cf 100644
--- a/usr.sbin/trpt/trpt.c
+++ b/usr.sbin/trpt/trpt.c
@@ -39,7 +39,7 @@ char copyright[] =
#ifndef lint
/*static char sccsid[] = "from: @(#)trpt.c 5.14 (Berkeley) 7/1/91";*/
-static char rcsid[] = "$Id: trpt.c,v 1.2 1996/05/30 09:11:11 deraadt Exp $";
+static char rcsid[] = "$Id: trpt.c,v 1.3 1996/06/03 18:06:18 deraadt Exp $";
#endif /* not lint */
#include <sys/param.h>
@@ -167,7 +167,7 @@ main(argc, argv)
* Discard setgid priviledges if not the running kernel so that bad
* guys can't print interesting stuff from kernel memory.
*/
- if (core != _PATH_KMEM || system != _PATH_UNIX)
+ if (!strcmp(core, _PATH_KMEM) || !strcmp(system, _PATH_UNIX))
setgid(getgid());
if (nlist(system, nl) < 0 || !nl[0].n_value) {