From b2ee1660ba2d5d3403da61ccd6a557960dc172c4 Mon Sep 17 00:00:00 2001 From: Peter Wemm Date: Tue, 4 Aug 1998 12:53:30 +0000 Subject: [PATCH] Copy respective revisions from usr.sbin/sendmail/*/* - use -1 with getopt. --- contrib/sendmail/contrib/bitdomain.c | 2 +- contrib/sendmail/mail.local/mail.local.c | 2 +- contrib/sendmail/mailstats/mailstats.c | 2 +- contrib/sendmail/makemap/makemap.c | 2 +- contrib/sendmail/praliases/praliases.c | 2 +- contrib/sendmail/rmail/rmail.c | 2 +- 6 files changed, 6 insertions(+), 6 deletions(-) diff --git a/contrib/sendmail/contrib/bitdomain.c b/contrib/sendmail/contrib/bitdomain.c index 52d6d2187c3..ec79b9506e4 100644 --- a/contrib/sendmail/contrib/bitdomain.c +++ b/contrib/sendmail/contrib/bitdomain.c @@ -51,7 +51,7 @@ char **argv; { int opt; - while ((opt = getopt(argc, argv, "o:")) != EOF) { + while ((opt = getopt(argc, argv, "o:")) != -1) { switch (opt) { case 'o': if (!freopen(optarg, "w", stdout)) { diff --git a/contrib/sendmail/mail.local/mail.local.c b/contrib/sendmail/mail.local/mail.local.c index a0f176f6381..8e47bbb3430 100644 --- a/contrib/sendmail/mail.local/mail.local.c +++ b/contrib/sendmail/mail.local/mail.local.c @@ -259,7 +259,7 @@ main(argc, argv) #endif from = NULL; - while ((ch = getopt(argc, argv, "df:r:l")) != EOF) + while ((ch = getopt(argc, argv, "df:r:l")) != -1) switch(ch) { case 'd': /* Backward compatible. */ break; diff --git a/contrib/sendmail/mailstats/mailstats.c b/contrib/sendmail/mailstats/mailstats.c index 6fda6db391a..9cd7cdb488d 100644 --- a/contrib/sendmail/mailstats/mailstats.c +++ b/contrib/sendmail/mailstats/mailstats.c @@ -55,7 +55,7 @@ main(argc, argv) cfile = _PATH_SENDMAILCF; sfile = NULL; mnames = TRUE; - while ((ch = getopt(argc, argv, "C:f:o")) != EOF) + while ((ch = getopt(argc, argv, "C:f:o")) != -1) { switch (ch) { diff --git a/contrib/sendmail/makemap/makemap.c b/contrib/sendmail/makemap/makemap.c index 53b5865606a..5891d75ce91 100644 --- a/contrib/sendmail/makemap/makemap.c +++ b/contrib/sendmail/makemap/makemap.c @@ -149,7 +149,7 @@ main(argc, argv) #else #define OPTIONS "C:Ndforsv" #endif - while ((opt = getopt(argc, argv, OPTIONS)) != EOF) + while ((opt = getopt(argc, argv, OPTIONS)) != -1) { switch (opt) { diff --git a/contrib/sendmail/praliases/praliases.c b/contrib/sendmail/praliases/praliases.c index 3e0048b4fc7..db7aa683adc 100644 --- a/contrib/sendmail/praliases/praliases.c +++ b/contrib/sendmail/praliases/praliases.c @@ -70,7 +70,7 @@ main(argc, argv) #endif filename = "/etc/aliases"; - while ((ch = getopt(argc, argv, "f:")) != EOF) + while ((ch = getopt(argc, argv, "f:")) != -1) switch((char)ch) { case 'f': filename = optarg; diff --git a/contrib/sendmail/rmail/rmail.c b/contrib/sendmail/rmail/rmail.c index 9d58fcc526b..5a1795a41e4 100644 --- a/contrib/sendmail/rmail/rmail.c +++ b/contrib/sendmail/rmail/rmail.c @@ -145,7 +145,7 @@ main(argc, argv) debug = 0; domain = "UUCP"; /* Default "domain". */ - while ((ch = getopt(argc, argv, "D:T")) != EOF) + while ((ch = getopt(argc, argv, "D:T")) != -1) switch (ch) { case 'T': debug = 1;