summaryrefslogtreecommitdiffstats
path: root/usr.bin/lam
diff options
context:
space:
mode:
authorjmallett <jmallett@FreeBSD.org>2002-06-27 21:11:19 +0000
committerjmallett <jmallett@FreeBSD.org>2002-06-27 21:11:19 +0000
commitfd8dc1333d32e1394441ee818cba3e0f8e23b052 (patch)
tree6f44c62fc57c348415ae6f03c459196704b0bd23 /usr.bin/lam
parent3e36f9e3d98e954aef3b51154a07c7484a5c5557 (diff)
downloadFreeBSD-src-fd8dc1333d32e1394441ee818cba3e0f8e23b052.zip
FreeBSD-src-fd8dc1333d32e1394441ee818cba3e0f8e23b052.tar.gz
Increment morefiles, balance braces. This should really be using getopt(3).
Diffstat (limited to 'usr.bin/lam')
-rw-r--r--usr.bin/lam/lam.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/usr.bin/lam/lam.c b/usr.bin/lam/lam.c
index 8a65a8d..e01fc9d 100644
--- a/usr.bin/lam/lam.c
+++ b/usr.bin/lam/lam.c
@@ -114,9 +114,10 @@ getargs(char *av[])
P = S = F = T = 0; /* capitalized options */
while ((p = *++av) != NULL) {
if (*p != '-' || !p[1]) {
- if (*p == '-')
+ morefiles++;
+ if (*p == '-') {
ip->fp = stdin;
- else if ((ip->fp = fopen(p, "r")) == NULL) {
+ } else if ((ip->fp = fopen(p, "r")) == NULL) {
err(1, "%s", p);
}
ip->pad = P;
OpenPOWER on IntegriCloud