summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTheo de Raadt <deraadt@cvs.openbsd.org>1999-12-03 23:43:03 +0000
committerTheo de Raadt <deraadt@cvs.openbsd.org>1999-12-03 23:43:03 +0000
commit1d6c9c163e7265474233814de2f2cdc914dc0208 (patch)
tree8249418b10dd52278286677764c10806188fd2a3
parent5f8099cb3b09d7c2a7115afab4efcc1526e58b12 (diff)
the -s option was broken; spotted by tstromberg@rtci.com on freebsd-audit, but i have not seen them fix any of the bugs
-rw-r--r--usr.bin/pr/pr.c15
1 files changed, 8 insertions, 7 deletions
diff --git a/usr.bin/pr/pr.c b/usr.bin/pr/pr.c
index de7836aefb4..197abac2e75 100644
--- a/usr.bin/pr/pr.c
+++ b/usr.bin/pr/pr.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: pr.c,v 1.6 1999/05/23 17:37:41 millert Exp $ */
+/* $OpenBSD: pr.c,v 1.7 1999/12/03 23:43:02 deraadt Exp $ */
/*-
* Copyright (c) 1991 Keith Muller.
@@ -45,7 +45,7 @@ static char copyright[] =
#ifndef lint
/* from: static char sccsid[] = "@(#)pr.c 8.1 (Berkeley) 6/6/93"; */
-static char *rcsid = "$OpenBSD: pr.c,v 1.6 1999/05/23 17:37:41 millert Exp $";
+static char *rcsid = "$OpenBSD: pr.c,v 1.7 1999/12/03 23:43:02 deraadt Exp $";
#endif /* not lint */
#include <sys/types.h>
@@ -1872,12 +1872,13 @@ setup(argc, argv)
++sflag;
if (eoptarg == NULL)
schar = SCHAR;
- else
+ else {
schar = *eoptarg++;
- if (*eoptarg != '\0') {
- (void)fprintf(err,
- "pr: invalid value for -s %s\n", eoptarg);
- return(1);
+ if (*eoptarg != '\0') {
+ (void)fprintf(err,
+ "pr: invalid value for -s %s\n", eoptarg);
+ return(1);
+ }
}
break;
case 't':