summaryrefslogtreecommitdiff
path: root/games
diff options
context:
space:
mode:
authorPaul Janzen <pjanzen@cvs.openbsd.org>2002-05-31 03:40:02 +0000
committerPaul Janzen <pjanzen@cvs.openbsd.org>2002-05-31 03:40:02 +0000
commit78168af82c4ec7ba2d8e9b500d667ee732db8e04 (patch)
treef01418ef860326642ed58e133f0fcd16b4655c37 /games
parentf539c9183476b44dd9dd78a973f4a09cd6089661 (diff)
No dm -> no need to revoke setegid.
Diffstat (limited to 'games')
-rw-r--r--games/adventure/main.c8
-rw-r--r--games/arithmetic/arithmetic.c8
-rw-r--r--games/backgammon/backgammon/main.c8
-rw-r--r--games/backgammon/teachgammon/teach.c8
-rw-r--r--games/banner/banner.c8
-rw-r--r--games/bcd/bcd.c8
-rw-r--r--games/boggle/boggle/bog.c8
-rw-r--r--games/bs/bs.c10
-rw-r--r--games/caesar/caesar.c12
-rw-r--r--games/factor/factor.c8
-rw-r--r--games/fish/fish.c8
-rw-r--r--games/gomoku/main.c8
-rw-r--r--games/grdc/grdc.c6
-rw-r--r--games/hangman/main.c8
-rw-r--r--games/hunt/hunt/hunt.c6
-rw-r--r--games/hunt/huntd/driver.c6
-rw-r--r--games/mille/mille.c8
-rw-r--r--games/monop/initdeck.c8
-rw-r--r--games/morse/morse.c8
-rw-r--r--games/number/number.c8
-rw-r--r--games/pig/pig.c8
-rw-r--r--games/pom/pom.c8
-rw-r--r--games/ppt/ppt.c16
-rw-r--r--games/primes/primes.c8
-rw-r--r--games/quiz/quiz.c8
-rw-r--r--games/rain/rain.c8
-rw-r--r--games/random/random.c8
-rw-r--r--games/trek/main.c8
-rw-r--r--games/worm/worm.c8
-rw-r--r--games/worms/worms.c8
-rw-r--r--games/wump/wump.c8
31 files changed, 66 insertions, 190 deletions
diff --git a/games/adventure/main.c b/games/adventure/main.c
index 73304326ba6..4295750c532 100644
--- a/games/adventure/main.c
+++ b/games/adventure/main.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: main.c,v 1.11 2001/02/04 06:07:20 pjanzen Exp $ */
+/* $OpenBSD: main.c,v 1.12 2002/05/31 03:39:55 pjanzen Exp $ */
/* $NetBSD: main.c,v 1.5 1996/05/21 21:53:09 mrg Exp $ */
/*-
@@ -49,7 +49,7 @@ static char copyright[] =
#if 0
static char sccsid[] = "@(#)main.c 8.1 (Berkeley) 6/2/93";
#else
-static char rcsid[] = "$OpenBSD: main.c,v 1.11 2001/02/04 06:07:20 pjanzen Exp $";
+static char rcsid[] = "$OpenBSD: main.c,v 1.12 2002/05/31 03:39:55 pjanzen Exp $";
#endif
#endif /* not lint */
@@ -72,10 +72,6 @@ main(argc, argv)
int rval, ll;
struct text *kk;
- /* revoke privs */
- setegid(getgid());
- setgid(getgid());
-
init(); /* Initialize everything */
signal(SIGINT, trapdel);
diff --git a/games/arithmetic/arithmetic.c b/games/arithmetic/arithmetic.c
index 61c3c92fc9e..5702cd15188 100644
--- a/games/arithmetic/arithmetic.c
+++ b/games/arithmetic/arithmetic.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: arithmetic.c,v 1.9 2002/02/16 21:27:08 millert Exp $ */
+/* $OpenBSD: arithmetic.c,v 1.10 2002/05/31 03:40:00 pjanzen Exp $ */
/*
* Copyright (c) 1989, 1993
@@ -46,7 +46,7 @@ static char copyright[] =
#if 0
static char sccsid[] = "@(#)arithmetic.c 8.1 (Berkeley) 5/31/93";
#else
-static char rcsid[] = "$OpenBSD: arithmetic.c,v 1.9 2002/02/16 21:27:08 millert Exp $";
+static char rcsid[] = "$OpenBSD: arithmetic.c,v 1.10 2002/05/31 03:40:00 pjanzen Exp $";
#endif
#endif /* not lint */
@@ -121,10 +121,6 @@ main(argc, argv)
extern int optind;
int ch, cnt;
- /* revoke privs */
- setegid(getgid());
- setgid(getgid());
-
while ((ch = getopt(argc, argv, "hr:o:")) != -1)
switch(ch) {
case 'o': {
diff --git a/games/backgammon/backgammon/main.c b/games/backgammon/backgammon/main.c
index d785da93da0..796bb03532e 100644
--- a/games/backgammon/backgammon/main.c
+++ b/games/backgammon/backgammon/main.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: main.c,v 1.10 2001/07/09 07:04:27 deraadt Exp $ */
+/* $OpenBSD: main.c,v 1.11 2002/05/31 03:40:00 pjanzen Exp $ */
/*
* Copyright (c) 1980, 1993
@@ -43,7 +43,7 @@ static char copyright[] =
#if 0
static char sccsid[] = "@(#)main.c 8.1 (Berkeley) 5/31/93";
#else
-static char rcsid[] = "$OpenBSD: main.c,v 1.10 2001/07/09 07:04:27 deraadt Exp $";
+static char rcsid[] = "$OpenBSD: main.c,v 1.11 2002/05/31 03:40:00 pjanzen Exp $";
#endif
#endif /* not lint */
@@ -107,10 +107,6 @@ main (argc,argv)
char c; /* non-descript character storage */
long t; /* time for random num generator */
- /* revoke privs */
- setegid(getgid());
- setgid(getgid());
-
signal(SIGINT, getout); /* trap interrupts */
initcurses();
diff --git a/games/backgammon/teachgammon/teach.c b/games/backgammon/teachgammon/teach.c
index 758e3921a8b..fce987a2e87 100644
--- a/games/backgammon/teachgammon/teach.c
+++ b/games/backgammon/teachgammon/teach.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: teach.c,v 1.10 2001/07/09 07:04:28 deraadt Exp $ */
+/* $OpenBSD: teach.c,v 1.11 2002/05/31 03:40:00 pjanzen Exp $ */
/*
* Copyright (c) 1980, 1993
@@ -43,7 +43,7 @@ static char copyright[] =
#if 0
static char sccsid[] = "@(#)teach.c 8.1 (Berkeley) 5/31/93";
#else
-static char rcsid[] = "$OpenBSD: teach.c,v 1.10 2001/07/09 07:04:28 deraadt Exp $";
+static char rcsid[] = "$OpenBSD: teach.c,v 1.11 2002/05/31 03:40:00 pjanzen Exp $";
#endif
#endif /* not lint */
@@ -73,10 +73,6 @@ main(argc, argv)
{
int i;
- /* revoke privs */
- setegid(getgid());
- setgid(getgid());
-
signal(SIGINT, getout);
initcurses();
text(hello);
diff --git a/games/banner/banner.c b/games/banner/banner.c
index e49f14fa603..08b60b4290f 100644
--- a/games/banner/banner.c
+++ b/games/banner/banner.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: banner.c,v 1.7 1998/09/15 05:22:46 pjanzen Exp $ */
+/* $OpenBSD: banner.c,v 1.8 2002/05/31 03:40:00 pjanzen Exp $ */
/* $NetBSD: banner.c,v 1.4 1995/04/22 11:55:15 cgd Exp $ */
/*
@@ -44,7 +44,7 @@ static char copyright[] =
#if 0
static char sccsid[] = "@(#)banner.c 8.3 (Berkeley) 4/2/94";
#else
-static char rcsid[] = "$OpenBSD: banner.c,v 1.7 1998/09/15 05:22:46 pjanzen Exp $";
+static char rcsid[] = "$OpenBSD: banner.c,v 1.8 2002/05/31 03:40:00 pjanzen Exp $";
#endif
#endif /* not lint */
@@ -1037,10 +1037,6 @@ main(argc, argv)
{
int ch;
- /* revoke */
- setegid(getgid());
- setgid(getgid());
-
while ((ch = getopt(argc, argv, "w:tdh")) != -1)
switch (ch) {
case 'd':
diff --git a/games/bcd/bcd.c b/games/bcd/bcd.c
index 5c58a84f478..54976c4b2f4 100644
--- a/games/bcd/bcd.c
+++ b/games/bcd/bcd.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: bcd.c,v 1.7 2002/02/16 21:27:09 millert Exp $ */
+/* $OpenBSD: bcd.c,v 1.8 2002/05/31 03:40:00 pjanzen Exp $ */
/* $NetBSD: bcd.c,v 1.6 1995/04/24 12:22:23 cgd Exp $ */
/*
@@ -47,7 +47,7 @@ static char copyright[] =
#if 0
static char sccsid[] = "@(#)bcd.c 8.2 (Berkeley) 3/20/94";
#else
-static char rcsid[] = "$OpenBSD: bcd.c,v 1.7 2002/02/16 21:27:09 millert Exp $";
+static char rcsid[] = "$OpenBSD: bcd.c,v 1.8 2002/05/31 03:40:00 pjanzen Exp $";
#endif
#endif /* not lint */
@@ -141,10 +141,6 @@ main(argc, argv)
* but this seems kind of silly. So this one doesn't.
*/
- /* revoke privs */
- setegid(getgid());
- setgid(getgid());
-
if (argc > 1) {
while (--argc)
printcard(*++argv);
diff --git a/games/boggle/boggle/bog.c b/games/boggle/boggle/bog.c
index bfe137545d5..a0cdb208ced 100644
--- a/games/boggle/boggle/bog.c
+++ b/games/boggle/boggle/bog.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: bog.c,v 1.8 2002/02/16 21:27:09 millert Exp $ */
+/* $OpenBSD: bog.c,v 1.9 2002/05/31 03:40:00 pjanzen Exp $ */
/* $NetBSD: bog.c,v 1.5 1995/04/24 12:22:32 cgd Exp $ */
/*-
@@ -47,7 +47,7 @@ static char copyright[] =
#if 0
static char sccsid[] = "@(#)bog.c 8.1 (Berkeley) 6/11/93";
#else
-static char rcsid[] = "$OpenBSD: bog.c,v 1.8 2002/02/16 21:27:09 millert Exp $";
+static char rcsid[] = "$OpenBSD: bog.c,v 1.9 2002/05/31 03:40:00 pjanzen Exp $";
#endif
#endif /* not lint */
@@ -133,10 +133,6 @@ main(argc, argv)
int ch, done, i, sflag;
char *bspec, *p;
- /* revoke */
- setegid(getgid());
- setgid(getgid());
-
seed = 0;
batch = debug = reuse = selfuse = sflag = 0;
bspec = NULL;
diff --git a/games/bs/bs.c b/games/bs/bs.c
index 92f20dff92f..a501907a06c 100644
--- a/games/bs/bs.c
+++ b/games/bs/bs.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: bs.c,v 1.12 2002/02/18 06:45:26 deraadt Exp $ */
+/* $OpenBSD: bs.c,v 1.13 2002/05/31 03:40:00 pjanzen Exp $ */
/*
* bs.c - original author: Bruce Holloway
* salvo option by: Chuck A DeGaul
@@ -11,10 +11,10 @@
*/
#ifndef lint
-static char rcsid[] = "$OpenBSD: bs.c,v 1.12 2002/02/18 06:45:26 deraadt Exp $";
+static char rcsid[] = "$OpenBSD: bs.c,v 1.13 2002/05/31 03:40:00 pjanzen Exp $";
#endif
-/* #define _POSIX_SOURCE */ /* (setegid, random) */
+/* #define _POSIX_SOURCE */ /* ( random() ) */
#include <sys/param.h>
#include <sys/types.h>
@@ -1347,10 +1347,6 @@ static int scount(int who)
int main(int argc, char *argv[])
{
- /* revoke privs */
- setegid(getgid());
- setgid(getgid());
-
do_options(argc, argv);
intro();
diff --git a/games/caesar/caesar.c b/games/caesar/caesar.c
index abba1c2e495..49e16e7d722 100644
--- a/games/caesar/caesar.c
+++ b/games/caesar/caesar.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: caesar.c,v 1.9 2002/02/16 21:27:09 millert Exp $ */
+/* $OpenBSD: caesar.c,v 1.10 2002/05/31 03:40:00 pjanzen Exp $ */
/*
* Copyright (c) 1989, 1993
@@ -51,7 +51,7 @@ static char copyright[] =
#if 0
static char sccsid[] = "@(#)caesar.c 8.1 (Berkeley) 5/31/93";
#else
-static char rcsid[] = "$OpenBSD: caesar.c,v 1.9 2002/02/16 21:27:09 millert Exp $";
+static char rcsid[] = "$OpenBSD: caesar.c,v 1.10 2002/05/31 03:40:00 pjanzen Exp $";
#endif
#endif /* not lint */
@@ -88,14 +88,10 @@ main(argc, argv)
int argc;
char **argv;
{
- register int ch, dot, i, nread, winnerdot;
- register char *inbuf, *p, **av;
+ int ch, dot, i, nread, winnerdot;
+ char *inbuf, *p, **av;
int obs[26], try, winner;
- /* revoke privs */
- setegid(getgid());
- setgid(getgid());
-
/* check to see if we were called as rot13 */
av = argv;
p = strrchr(*av, '/');
diff --git a/games/factor/factor.c b/games/factor/factor.c
index c899b387994..262e14bbac3 100644
--- a/games/factor/factor.c
+++ b/games/factor/factor.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: factor.c,v 1.12 2002/02/16 21:27:09 millert Exp $ */
+/* $OpenBSD: factor.c,v 1.13 2002/05/31 03:40:00 pjanzen Exp $ */
/* $NetBSD: factor.c,v 1.5 1995/03/23 08:28:07 cgd Exp $ */
/*
@@ -47,7 +47,7 @@ static char copyright[] =
#if 0
static char sccsid[] = "@(#)factor.c 8.4 (Berkeley) 5/4/95";
#else
-static char rcsid[] = "$OpenBSD: factor.c,v 1.12 2002/02/16 21:27:09 millert Exp $";
+static char rcsid[] = "$OpenBSD: factor.c,v 1.13 2002/05/31 03:40:00 pjanzen Exp $";
#endif
#endif /* not lint */
@@ -107,10 +107,6 @@ main(argc, argv)
int ch;
char *p, buf[100]; /* > max number of digits. */
- /* revoke privs */
- setegid(getgid());
- setgid(getgid());
-
while ((ch = getopt(argc, argv, "")) != -1)
switch (ch) {
case '?':
diff --git a/games/fish/fish.c b/games/fish/fish.c
index eeb77efd914..da2e80bef27 100644
--- a/games/fish/fish.c
+++ b/games/fish/fish.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: fish.c,v 1.10 2002/02/16 21:27:09 millert Exp $ */
+/* $OpenBSD: fish.c,v 1.11 2002/05/31 03:40:00 pjanzen Exp $ */
/* $NetBSD: fish.c,v 1.3 1995/03/23 08:28:18 cgd Exp $ */
/*-
@@ -47,7 +47,7 @@ static char copyright[] =
#if 0
static char sccsid[] = "@(#)fish.c 8.1 (Berkeley) 5/31/93";
#else
-static char rcsid[] = "$OpenBSD: fish.c,v 1.10 2002/02/16 21:27:09 millert Exp $";
+static char rcsid[] = "$OpenBSD: fish.c,v 1.11 2002/05/31 03:40:00 pjanzen Exp $";
#endif
#endif /* not lint */
@@ -107,10 +107,6 @@ main(argc, argv)
{
int ch, move;
- /* revoke privs */
- setegid(getgid());
- setgid(getgid());
-
while ((ch = getopt(argc, argv, "ph")) != -1)
switch(ch) {
case 'p':
diff --git a/games/gomoku/main.c b/games/gomoku/main.c
index c84f1e52105..eced3fb0962 100644
--- a/games/gomoku/main.c
+++ b/games/gomoku/main.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: main.c,v 1.11 2001/03/30 04:40:07 pjanzen Exp $ */
+/* $OpenBSD: main.c,v 1.12 2002/05/31 03:40:00 pjanzen Exp $ */
/*
* Copyright (c) 1994
* The Regents of the University of California. All rights reserved.
@@ -45,7 +45,7 @@ static char copyright[] =
#if 0
static char sccsid[] = "@(#)main.c 8.4 (Berkeley) 5/4/95";
#else
-static char rcsid[] = "$OpenBSD: main.c,v 1.11 2001/03/30 04:40:07 pjanzen Exp $";
+static char rcsid[] = "$OpenBSD: main.c,v 1.12 2002/05/31 03:40:00 pjanzen Exp $";
#endif
#endif /* not lint */
@@ -99,10 +99,6 @@ main(argc, argv)
};
char *tmpname;
- /* revoke privs */
- setegid(getgid());
- setgid(getgid());
-
prog = strrchr(argv[0], '/');
if (prog)
prog++;
diff --git a/games/grdc/grdc.c b/games/grdc/grdc.c
index fed0dd8aa3d..8b5fb569c02 100644
--- a/games/grdc/grdc.c
+++ b/games/grdc/grdc.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: grdc.c,v 1.10 2002/02/16 21:27:10 millert Exp $ */
+/* $OpenBSD: grdc.c,v 1.11 2002/05/31 03:40:00 pjanzen Exp $ */
/*
* Grand digital clock for curses compatible terminals
* Usage: grdc [-s] [n] -- run for n seconds (default infinity)
@@ -60,10 +60,6 @@ main(argc, argv)
struct timespec delay;
char *ep;
- /* revoke privs */
- setegid(getgid());
- setgid(getgid());
-
scrol = 0;
while ((i = getopt(argc, argv, "sh")) != -1)
switch (i) {
diff --git a/games/hangman/main.c b/games/hangman/main.c
index 4417848caa7..df35ca5c763 100644
--- a/games/hangman/main.c
+++ b/games/hangman/main.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: main.c,v 1.6 1999/09/25 20:51:53 pjanzen Exp $ */
+/* $OpenBSD: main.c,v 1.7 2002/05/31 03:40:00 pjanzen Exp $ */
/* $NetBSD: main.c,v 1.3 1995/03/23 08:32:50 cgd Exp $ */
/*
@@ -44,7 +44,7 @@ static char copyright[] =
#if 0
static char sccsid[] = "@(#)main.c 8.1 (Berkeley) 5/31/93";
#else
-static char rcsid[] = "$OpenBSD: main.c,v 1.6 1999/09/25 20:51:53 pjanzen Exp $";
+static char rcsid[] = "$OpenBSD: main.c,v 1.7 2002/05/31 03:40:00 pjanzen Exp $";
#endif
#endif /* not lint */
@@ -60,10 +60,6 @@ main(argc, argv)
{
int ch;
- /* revoke */
- setegid(getgid());
- setgid(getgid());
-
while ((ch = getopt(argc, argv, "d:h")) != -1) {
switch (ch) {
case 'd':
diff --git a/games/hunt/hunt/hunt.c b/games/hunt/hunt/hunt.c
index 13013bc0514..1ef52bcee32 100644
--- a/games/hunt/hunt/hunt.c
+++ b/games/hunt/hunt/hunt.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: hunt.c,v 1.9 2002/02/16 21:27:10 millert Exp $ */
+/* $OpenBSD: hunt.c,v 1.10 2002/05/31 03:40:00 pjanzen Exp $ */
/* $NetBSD: hunt.c,v 1.8 1998/09/13 15:27:28 hubertf Exp $ */
/*
* Hunt
@@ -78,10 +78,6 @@ main(ac, av)
int option;
struct servent *se;
- /* Revoke privs: */
- setegid(getgid());
- setgid(getgid());
-
enter_status = env_init((long) Q_CLOAK);
while ((c = getopt(ac, av, "Sbcfh:l:mn:op:qst:w:")) != -1) {
switch (c) {
diff --git a/games/hunt/huntd/driver.c b/games/hunt/huntd/driver.c
index d893ce294e6..36fd403083d 100644
--- a/games/hunt/huntd/driver.c
+++ b/games/hunt/huntd/driver.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: driver.c,v 1.11 2002/02/16 21:27:10 millert Exp $ */
+/* $OpenBSD: driver.c,v 1.12 2002/05/31 03:40:00 pjanzen Exp $ */
/* $NetBSD: driver.c,v 1.5 1997/10/20 00:37:16 lukem Exp $ */
/*
* Hunt
@@ -74,10 +74,6 @@ main(ac, av)
First_arg = av[0];
- /* Revoke privs: */
- setegid(getgid());
- setgid(getgid());
-
config();
while ((c = getopt(ac, av, "sp:a:D:")) != -1) {
diff --git a/games/mille/mille.c b/games/mille/mille.c
index e7fe597507f..68fc3f88c88 100644
--- a/games/mille/mille.c
+++ b/games/mille/mille.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: mille.c,v 1.10 2001/09/03 21:36:12 pjanzen Exp $ */
+/* $OpenBSD: mille.c,v 1.11 2002/05/31 03:40:01 pjanzen Exp $ */
/* $NetBSD: mille.c,v 1.4 1995/03/24 05:01:48 cgd Exp $ */
/*
@@ -44,7 +44,7 @@ static char copyright[] =
#if 0
static char sccsid[] = "@(#)mille.c 8.1 (Berkeley) 5/31/93";
#else
-static char rcsid[] = "$OpenBSD: mille.c,v 1.10 2001/09/03 21:36:12 pjanzen Exp $";
+static char rcsid[] = "$OpenBSD: mille.c,v 1.11 2002/05/31 03:40:01 pjanzen Exp $";
#endif
#endif /* not lint */
@@ -62,10 +62,6 @@ main(ac, av)
{
bool restore;
- /* revoke */
- setegid(getgid());
- setgid(getgid());
-
#ifdef DEBUG
if (strcmp(av[0], "a.out") == 0) {
outf = fopen("q", "w");
diff --git a/games/monop/initdeck.c b/games/monop/initdeck.c
index d86e1ad9d52..8f844ad4223 100644
--- a/games/monop/initdeck.c
+++ b/games/monop/initdeck.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: initdeck.c,v 1.9 2002/02/16 21:27:10 millert Exp $ */
+/* $OpenBSD: initdeck.c,v 1.10 2002/05/31 03:40:01 pjanzen Exp $ */
/* $NetBSD: initdeck.c,v 1.3 1995/03/23 08:34:43 cgd Exp $ */
/*
@@ -44,7 +44,7 @@ static char copyright[] =
#if 0
static char sccsid[] = "@(#)initdeck.c 8.1 (Berkeley) 5/31/93";
#else
-static char rcsid[] = "$OpenBSD: initdeck.c,v 1.9 2002/02/16 21:27:10 millert Exp $";
+static char rcsid[] = "$OpenBSD: initdeck.c,v 1.10 2002/05/31 03:40:01 pjanzen Exp $";
#endif
#endif /* not lint */
@@ -88,10 +88,6 @@ main(ac, av)
{
int n;
- /* revoke */
- setegid(getgid());
- setgid(getgid());
-
getargs(ac, av);
if ((inf = fopen(infile, "r")) == NULL)
err(1, "%s", infile);
diff --git a/games/morse/morse.c b/games/morse/morse.c
index 9849eda017b..ce60212b482 100644
--- a/games/morse/morse.c
+++ b/games/morse/morse.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: morse.c,v 1.8 2002/02/16 21:27:11 millert Exp $ */
+/* $OpenBSD: morse.c,v 1.9 2002/05/31 03:40:01 pjanzen Exp $ */
/*
* Copyright (c) 1988, 1993
@@ -43,7 +43,7 @@ static char copyright[] =
#if 0
static char sccsid[] = "@(#)morse.c 8.1 (Berkeley) 5/31/93";
#else
-static char rcsid[] = "$OpenBSD: morse.c,v 1.8 2002/02/16 21:27:11 millert Exp $";
+static char rcsid[] = "$OpenBSD: morse.c,v 1.9 2002/05/31 03:40:01 pjanzen Exp $";
#endif
#endif /* not lint */
@@ -130,10 +130,6 @@ main(argc, argv)
int ch;
char *p;
- /* revoke */
- setegid(getgid());
- setgid(getgid());
-
while ((ch = getopt(argc, argv, "dsh")) != -1)
switch((char)ch) {
case 'd':
diff --git a/games/number/number.c b/games/number/number.c
index 237b15784ad..98fcdbf63ff 100644
--- a/games/number/number.c
+++ b/games/number/number.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: number.c,v 1.8 2002/02/16 21:27:11 millert Exp $ */
+/* $OpenBSD: number.c,v 1.9 2002/05/31 03:40:01 pjanzen Exp $ */
/*
* Copyright (c) 1988, 1993, 1994
@@ -43,7 +43,7 @@ static char copyright[] =
#if 0
static char sccsid[] = "@(#)number.c 8.3 (Berkeley) 5/4/95";
#else
-static char rcsid[] = "$OpenBSD: number.c,v 1.8 2002/02/16 21:27:11 millert Exp $";
+static char rcsid[] = "$OpenBSD: number.c,v 1.9 2002/05/31 03:40:01 pjanzen Exp $";
#endif
#endif /* not lint */
@@ -99,10 +99,6 @@ main(argc, argv)
int ch, first;
char line[LINELEN];
- /* revoke */
- setegid(getgid());
- setgid(getgid());
-
lflag = 0;
while ((ch = getopt(argc, argv, "hl")) != -1)
switch (ch) {
diff --git a/games/pig/pig.c b/games/pig/pig.c
index 3f636d697f5..95792005504 100644
--- a/games/pig/pig.c
+++ b/games/pig/pig.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: pig.c,v 1.7 2002/02/16 21:27:11 millert Exp $ */
+/* $OpenBSD: pig.c,v 1.8 2002/05/31 03:40:01 pjanzen Exp $ */
/* $NetBSD: pig.c,v 1.2 1995/03/23 08:41:40 cgd Exp $ */
/*-
@@ -44,7 +44,7 @@ static char copyright[] =
#if 0
static char sccsid[] = "@(#)pig.c 8.2 (Berkeley) 5/4/95";
#else
-static char rcsid[] = "$OpenBSD: pig.c,v 1.7 2002/02/16 21:27:11 millert Exp $";
+static char rcsid[] = "$OpenBSD: pig.c,v 1.8 2002/05/31 03:40:01 pjanzen Exp $";
#endif
#endif /* not lint */
@@ -69,10 +69,6 @@ main(argc, argv)
int ch;
char buf[1024];
- /* revoke */
- setegid(getgid());
- setgid(getgid());
-
while ((ch = getopt(argc, argv, "")) != -1)
switch(ch) {
case '?':
diff --git a/games/pom/pom.c b/games/pom/pom.c
index d00659bbafd..6bc6789d243 100644
--- a/games/pom/pom.c
+++ b/games/pom/pom.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: pom.c,v 1.7 2002/02/16 21:27:11 millert Exp $ */
+/* $OpenBSD: pom.c,v 1.8 2002/05/31 03:40:01 pjanzen Exp $ */
/* $NetBSD: pom.c,v 1.6 1996/02/06 22:47:29 jtc Exp $ */
/*
@@ -46,7 +46,7 @@ static char copyright[] =
#if 0
static char sccsid[] = "@(#)pom.c 8.1 (Berkeley) 5/31/93";
#else
-static char rcsid[] = "$OpenBSD: pom.c,v 1.7 2002/02/16 21:27:11 millert Exp $";
+static char rcsid[] = "$OpenBSD: pom.c,v 1.8 2002/05/31 03:40:01 pjanzen Exp $";
#endif
#endif /* not lint */
@@ -103,10 +103,6 @@ main(argc, argv)
int cnt;
char buf[1024];
- /* revoke */
- setegid(getgid());
- setgid(getgid());
-
if (argc > 1) {
tmpt = parsetime(argv[1]);
strftime(buf, sizeof(buf), "%a %Y %b %e %H:%M:%S (%Z)",
diff --git a/games/ppt/ppt.c b/games/ppt/ppt.c
index 3cfe0bc87db..3238f3ae5bf 100644
--- a/games/ppt/ppt.c
+++ b/games/ppt/ppt.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ppt.c,v 1.6 2002/02/16 21:27:11 millert Exp $ */
+/* $OpenBSD: ppt.c,v 1.7 2002/05/31 03:40:01 pjanzen Exp $ */
/* $NetBSD: ppt.c,v 1.4 1995/03/23 08:35:40 cgd Exp $ */
/*
@@ -44,7 +44,7 @@ static char copyright[] =
#if 0
static char sccsid[] = "@(#)ppt.c 8.1 (Berkeley) 5/31/93";
#else
-static char rcsid[] = "$OpenBSD: ppt.c,v 1.6 2002/02/16 21:27:11 millert Exp $";
+static char rcsid[] = "$OpenBSD: ppt.c,v 1.7 2002/05/31 03:40:01 pjanzen Exp $";
#endif
#endif /* not lint */
@@ -59,12 +59,8 @@ main(argc, argv)
int argc;
char **argv;
{
- register int c;
- register char *p;
-
- /* revoke */
- setegid(getgid());
- setgid(getgid());
+ int c;
+ char *p;
(void) puts("___________");
if (argc > 1)
@@ -82,9 +78,9 @@ main(argc, argv)
static void
putppt(c)
- register int c;
+ int c;
{
- register int i;
+ int i;
(void) putchar('|');
for (i = 7; i >= 0; i--) {
diff --git a/games/primes/primes.c b/games/primes/primes.c
index 3941088261b..fdd7e1a46ae 100644
--- a/games/primes/primes.c
+++ b/games/primes/primes.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: primes.c,v 1.10 2002/02/16 21:27:11 millert Exp $ */
+/* $OpenBSD: primes.c,v 1.11 2002/05/31 03:40:01 pjanzen Exp $ */
/* $NetBSD: primes.c,v 1.5 1995/04/24 12:24:47 cgd Exp $ */
/*
@@ -47,7 +47,7 @@ static char copyright[] =
#if 0
static char sccsid[] = "@(#)primes.c 8.5 (Berkeley) 5/10/95";
#else
-static char rcsid[] = "$OpenBSD: primes.c,v 1.10 2002/02/16 21:27:11 millert Exp $";
+static char rcsid[] = "$OpenBSD: primes.c,v 1.11 2002/05/31 03:40:01 pjanzen Exp $";
#endif
#endif /* not lint */
@@ -123,10 +123,6 @@ main(argc, argv)
int ch;
char *p;
- /* revoke */
- setegid(getgid());
- setgid(getgid());
-
while ((ch = getopt(argc, argv, "")) != -1)
switch (ch) {
case '?':
diff --git a/games/quiz/quiz.c b/games/quiz/quiz.c
index ce73b3bfceb..5815b5cae8f 100644
--- a/games/quiz/quiz.c
+++ b/games/quiz/quiz.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: quiz.c,v 1.10 2002/02/16 21:27:11 millert Exp $ */
+/* $OpenBSD: quiz.c,v 1.11 2002/05/31 03:40:01 pjanzen Exp $ */
/* $NetBSD: quiz.c,v 1.9 1995/04/22 10:16:58 cgd Exp $ */
/*-
@@ -48,7 +48,7 @@ static char copyright[] =
#if 0
static char sccsid[] = "@(#)quiz.c 8.3 (Berkeley) 5/4/95";
#else
-static char rcsid[] = "$OpenBSD: quiz.c,v 1.10 2002/02/16 21:27:11 millert Exp $";
+static char rcsid[] = "$OpenBSD: quiz.c,v 1.11 2002/05/31 03:40:01 pjanzen Exp $";
#endif
#endif /* not lint */
@@ -86,10 +86,6 @@ main(argc, argv)
int ch;
const char *indexfile;
- /* revoke */
- setegid(getgid());
- setgid(getgid());
-
indexfile = _PATH_QUIZIDX;
while ((ch = getopt(argc, argv, "i:t")) != -1)
switch(ch) {
diff --git a/games/rain/rain.c b/games/rain/rain.c
index 78a1543545a..920670fc249 100644
--- a/games/rain/rain.c
+++ b/games/rain/rain.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: rain.c,v 1.10 2002/02/16 21:27:11 millert Exp $ */
+/* $OpenBSD: rain.c,v 1.11 2002/05/31 03:40:01 pjanzen Exp $ */
/*
* Copyright (c) 1980, 1993
@@ -43,7 +43,7 @@ static char copyright[] =
#if 0
static char sccsid[] = "@(#)rain.c 8.1 (Berkeley) 5/31/93";
#else
-static char rcsid[] = "$OpenBSD: rain.c,v 1.10 2002/02/16 21:27:11 millert Exp $";
+static char rcsid[] = "$OpenBSD: rain.c,v 1.11 2002/05/31 03:40:01 pjanzen Exp $";
#endif
#endif /* not lint */
@@ -76,10 +76,6 @@ main(argc, argv)
int ch;
int xpos[5], ypos[5];
- /* revoke */
- setegid(getgid());
- setgid(getgid());
-
while ((ch = getopt(argc, argv, "d:h")) != -1)
switch(ch) {
case 'd':
diff --git a/games/random/random.c b/games/random/random.c
index ed52a55adf5..ed09426d328 100644
--- a/games/random/random.c
+++ b/games/random/random.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: random.c,v 1.7 2002/02/16 21:27:11 millert Exp $ */
+/* $OpenBSD: random.c,v 1.8 2002/05/31 03:40:01 pjanzen Exp $ */
/* $NetBSD: random.c,v 1.3 1995/04/22 07:44:05 cgd Exp $ */
/*
@@ -47,7 +47,7 @@ static char copyright[] =
#if 0
static char sccsid[] = "@(#)random.c 8.5 (Berkeley) 4/5/94";
#else
-static char rcsid[] = "$OpenBSD: random.c,v 1.7 2002/02/16 21:27:11 millert Exp $";
+static char rcsid[] = "$OpenBSD: random.c,v 1.8 2002/05/31 03:40:01 pjanzen Exp $";
#endif
#endif /* not lint */
@@ -74,10 +74,6 @@ main(argc, argv)
int ch, random_exit, selected, unbuffer_output;
char *ep;
- /* revoke privs */
- setegid(getgid());
- setgid(getgid());
-
random_exit = unbuffer_output = 0;
while ((ch = getopt(argc, argv, "erh")) != -1)
switch (ch) {
diff --git a/games/trek/main.c b/games/trek/main.c
index 09c55591901..0c0af8c127a 100644
--- a/games/trek/main.c
+++ b/games/trek/main.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: main.c,v 1.7 1999/03/12 03:02:42 pjanzen Exp $ */
+/* $OpenBSD: main.c,v 1.8 2002/05/31 03:40:01 pjanzen Exp $ */
/* $NetBSD: main.c,v 1.4 1995/04/22 10:59:10 cgd Exp $ */
/*
@@ -44,7 +44,7 @@ static char copyright[] =
#if 0
static char sccsid[] = "@(#)main.c 8.1 (Berkeley) 5/31/93";
#else
-static char rcsid[] = "$OpenBSD: main.c,v 1.7 1999/03/12 03:02:42 pjanzen Exp $";
+static char rcsid[] = "$OpenBSD: main.c,v 1.8 2002/05/31 03:40:01 pjanzen Exp $";
#endif
#endif /* not lint */
@@ -143,10 +143,6 @@ main(argc, argv)
register int ac;
register char **av;
- /* revoke privs */
- setegid(getgid());
- setgid(getgid());
-
av = argv;
ac = argc;
av++;
diff --git a/games/worm/worm.c b/games/worm/worm.c
index 87ddc05d550..2caad28b453 100644
--- a/games/worm/worm.c
+++ b/games/worm/worm.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: worm.c,v 1.15 2002/02/16 21:27:12 millert Exp $ */
+/* $OpenBSD: worm.c,v 1.16 2002/05/31 03:40:01 pjanzen Exp $ */
/*
* Copyright (c) 1980, 1993
@@ -43,7 +43,7 @@ static char copyright[] =
#if 0
static char sccsid[] = "@(#)worm.c 8.1 (Berkeley) 5/31/93";
#else
-static char rcsid[] = "$OpenBSD: worm.c,v 1.15 2002/02/16 21:27:12 millert Exp $";
+static char rcsid[] = "$OpenBSD: worm.c,v 1.16 2002/05/31 03:40:01 pjanzen Exp $";
#endif
#endif /* not lint */
@@ -110,10 +110,6 @@ main(argc, argv)
struct timezone tz;
fd_set rset;
- /* revoke */
- setegid(getgid());
- setgid(getgid());
-
FD_ZERO(&rset);
setbuf(stdout, outbuf);
srandom(getpid());
diff --git a/games/worms/worms.c b/games/worms/worms.c
index 08b32b0c3e2..acd076ffe57 100644
--- a/games/worms/worms.c
+++ b/games/worms/worms.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: worms.c,v 1.11 2002/02/16 21:27:12 millert Exp $ */
+/* $OpenBSD: worms.c,v 1.12 2002/05/31 03:40:01 pjanzen Exp $ */
/*
* Copyright (c) 1980, 1993
@@ -43,7 +43,7 @@ static char copyright[] =
#if 0
static char sccsid[] = "@(#)worms.c 8.1 (Berkeley) 5/31/93";
#else
-static char rcsid[] = "$OpenBSD: worms.c,v 1.11 2002/02/16 21:27:12 millert Exp $";
+static char rcsid[] = "$OpenBSD: worms.c,v 1.12 2002/05/31 03:40:01 pjanzen Exp $";
#endif
#endif /* not lint */
@@ -199,10 +199,6 @@ main(argc, argv)
const char *field;
u_int delay = 0;
- /* revoke */
- setegid(getgid());
- setgid(getgid());
-
length = 16;
number = 3;
trail = ' ';
diff --git a/games/wump/wump.c b/games/wump/wump.c
index adfeb3cbb47..acdb2c0b04e 100644
--- a/games/wump/wump.c
+++ b/games/wump/wump.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: wump.c,v 1.17 2002/02/16 21:27:12 millert Exp $ */
+/* $OpenBSD: wump.c,v 1.18 2002/05/31 03:40:01 pjanzen Exp $ */
/*
* Copyright (c) 1989, 1993
@@ -47,7 +47,7 @@ static char copyright[] =
#if 0
static char sccsid[] = "@(#)wump.c 8.1 (Berkeley) 5/31/93";
#else
-static char rcsid[] = "$OpenBSD: wump.c,v 1.17 2002/02/16 21:27:12 millert Exp $";
+static char rcsid[] = "$OpenBSD: wump.c,v 1.18 2002/05/31 03:40:01 pjanzen Exp $";
#endif
#endif /* not lint */
@@ -155,10 +155,6 @@ main(argc, argv)
{
int c;
- /* revoke */
- setegid(getgid());
- setgid(getgid());
-
#ifdef DEBUG
while ((c = getopt(argc, argv, "a:b:hop:r:t:d")) != -1)
#else