diff options
author | Paul Janzen <pjanzen@cvs.openbsd.org> | 1999-03-27 03:45:51 +0000 |
---|---|---|
committer | Paul Janzen <pjanzen@cvs.openbsd.org> | 1999-03-27 03:45:51 +0000 |
commit | f51cf7f2e10053f45c0ffa2e95347f56d2eecce7 (patch) | |
tree | 36f2fd5bc053b41ba6a744a078f5d81e0a22c0dd /games/larn/tok.c | |
parent | 5190786085567acf6f269919dffc1b455a46988c (diff) |
Changes from FreeBSD: install score files, use random(), and be more careful
on exec.
Diffstat (limited to 'games/larn/tok.c')
-rw-r--r-- | games/larn/tok.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/games/larn/tok.c b/games/larn/tok.c index f295bab2b76..432d58d677c 100644 --- a/games/larn/tok.c +++ b/games/larn/tok.c @@ -1,9 +1,9 @@ -/* $OpenBSD: tok.c,v 1.2 1998/09/15 05:12:33 pjanzen Exp $ */ +/* $OpenBSD: tok.c,v 1.3 1999/03/27 03:45:50 pjanzen Exp $ */ /* $NetBSD: tok.c,v 1.5 1997/10/18 20:03:54 christos Exp $ */ /* tok.c Larn is copyrighted 1986 by Noah Morgan. */ #ifndef lint -static char rcsid[] = "$OpenBSD: tok.c,v 1.2 1998/09/15 05:12:33 pjanzen Exp $"; +static char rcsid[] = "$OpenBSD: tok.c,v 1.3 1999/03/27 03:45:50 pjanzen Exp $"; #endif /* not lint */ #include <sys/types.h> @@ -63,7 +63,7 @@ yylex() * finish */ if (fork() == 0) { savegame(ckpfile); - exit(); + exit(0); } #endif @@ -99,6 +99,8 @@ yylex() clear();/* scrolling region, home, clear, no * attributes */ if ((ic = fork()) == 0) { /* child */ + /* revoke */ + setgid(getgid()); execl("/bin/csh", 0); exit(1); } |