From 2c7dd28cfc8260d17279e6710dcda6d1eb9f7929 Mon Sep 17 00:00:00 2001 From: "Todd C. Miller" Date: Tue, 25 May 1999 16:40:56 +0000 Subject: for getopt, check rval != -1, not > 0 --- libexec/smtpd/src/smtpd.c | 6 +++--- libexec/smtpd/src/smtpfwdd.c | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/libexec/smtpd/src/smtpd.c b/libexec/smtpd/src/smtpd.c index 1a89e2a86d9..31e4dc6d25e 100644 --- a/libexec/smtpd/src/smtpd.c +++ b/libexec/smtpd/src/smtpd.c @@ -2,7 +2,7 @@ * smtpd, Obtuse SMTP daemon, storing agent. does simple collection of * mail messages, for later forwarding by smtpfwdd. * - * $Id: smtpd.c,v 1.7 1998/07/10 08:06:15 deraadt Exp $ + * $Id: smtpd.c,v 1.8 1999/05/25 16:40:55 millert Exp $ * * Copyright (c) 1996, 1997 Obtuse Systems Corporation. All rights * reserved. @@ -40,7 +40,7 @@ char *obtuse_copyright = "Copyright 1996 - Obtuse Systems Corporation - All rights reserved."; -char *obtuse_rcsid = "$Id: smtpd.c,v 1.7 1998/07/10 08:06:15 deraadt Exp $"; +char *obtuse_rcsid = "$Id: smtpd.c,v 1.8 1999/05/25 16:40:55 millert Exp $"; #include #include @@ -2065,7 +2065,7 @@ main(int argc, char **argv) #ifdef GETOPT_EOF while ((opt = getopt(argc, argv, optstring)) != EOF) { #else - while ((opt = getopt(argc, argv, optstring)) > 0) { + while ((opt = getopt(argc, argv, optstring)) != -1) { #endif switch (opt) { case 'p': diff --git a/libexec/smtpd/src/smtpfwdd.c b/libexec/smtpd/src/smtpfwdd.c index 612e4bd14c2..0214df4f303 100644 --- a/libexec/smtpd/src/smtpfwdd.c +++ b/libexec/smtpd/src/smtpfwdd.c @@ -4,7 +4,7 @@ * to pick it up and invokes sendmail (or sendmail-like agent) to * deliver it. * - * $Id: smtpfwdd.c,v 1.3 1998/06/03 08:57:14 beck Exp $ + * $Id: smtpfwdd.c,v 1.4 1999/05/25 16:40:55 millert Exp $ * * Copyright (c) 1996, 1997 Obtuse Systems Corporation. All rights * reserved. @@ -41,7 +41,7 @@ */ char *obtuse_copyright = "Copyright 1996 - Obtuse Systems Corporation - All rights reserved."; -char *obtuse_rcsid = "$Id: smtpfwdd.c,v 1.3 1998/06/03 08:57:14 beck Exp $"; +char *obtuse_rcsid = "$Id: smtpfwdd.c,v 1.4 1999/05/25 16:40:55 millert Exp $"; #include #include @@ -793,7 +793,7 @@ main(int argc, char **argv) #ifdef GETOPT_EOF while ((opt = getopt(argc, argv, optstring)) != EOF) { #else - while ((opt = getopt(argc, argv, optstring)) > 0) { + while ((opt = getopt(argc, argv, optstring)) != -1) { #endif switch (opt) { case 'q': -- cgit v1.2.3