summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTodd C. Miller <millert@cvs.openbsd.org>1997-09-12 04:35:19 +0000
committerTodd C. Miller <millert@cvs.openbsd.org>1997-09-12 04:35:19 +0000
commit7186cb669c627520462256325a3c6f8693991d67 (patch)
tree93cf3832410368d6f6f720b0a16a89727ff52b19
parentadbb428458ebac0b39bb28834f9679289ed38cf1 (diff)
Avoid longjmp/vfork clobbering.
-rw-r--r--bin/ed/main.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/bin/ed/main.c b/bin/ed/main.c
index e034b58b7a6..8fb008fe62c 100644
--- a/bin/ed/main.c
+++ b/bin/ed/main.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: main.c,v 1.12 1997/09/01 18:29:30 deraadt Exp $ */
+/* $OpenBSD: main.c,v 1.13 1997/09/12 04:35:18 millert Exp $ */
/* $NetBSD: main.c,v 1.3 1995/03/21 09:04:44 cgd Exp $ */
/* main.c: This file contains the main control and user-interface routines
@@ -39,7 +39,7 @@ char *copyright =
#if 0
static char *rcsid = "@(#)main.c,v 1.1 1994/02/01 00:34:42 alm Exp";
#else
-static char rcsid[] = "$OpenBSD: main.c,v 1.12 1997/09/01 18:29:30 deraadt Exp $";
+static char rcsid[] = "$OpenBSD: main.c,v 1.13 1997/09/12 04:35:18 millert Exp $";
#endif
#endif /* not lint */
@@ -118,6 +118,11 @@ main(argc, argv)
int c, n;
long status = 0;
+#ifdef __GNUC__
+ (void)&argc;
+ (void)&argv;
+#endif
+
red = (n = strlen(argv[0])) > 2 && argv[0][n - 3] == 'r';
top:
while ((c = getopt(argc, argv, "p:sx")) != -1)