From 2b4b5d51fdeac813b3213f4515b3148685e15993 Mon Sep 17 00:00:00 2001 From: Theodore Tso Date: Wed, 6 May 1998 20:35:03 +0000 Subject: [PATCH] POSIX states that getopt returns -1 when it is done parsing options, not EOF. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@10552 dc483132-0cff-0310-8789-dd5450dbe970 --- src/kadmin/v4server/ChangeLog | 5 +++++ src/kadmin/v4server/admin_server.c | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/src/kadmin/v4server/ChangeLog b/src/kadmin/v4server/ChangeLog index d64d0850a..d4c952cc4 100644 --- a/src/kadmin/v4server/ChangeLog +++ b/src/kadmin/v4server/ChangeLog @@ -1,3 +1,8 @@ +1998-05-06 Theodore Ts'o + + * admin_server.c (argv): POSIX states that getopt returns -1 + when it is done parsing options, not EOF. + Fri Feb 27 23:32:38 1998 Theodore Ts'o * Makefile.in: Changed thisconfigdir to point at the kadmin diff --git a/src/kadmin/v4server/admin_server.c b/src/kadmin/v4server/admin_server.c index 8dc97b90c..9cd2f8fb5 100644 --- a/src/kadmin/v4server/admin_server.c +++ b/src/kadmin/v4server/admin_server.c @@ -117,7 +117,7 @@ char *argv[]; memset(krbrlm, 0, sizeof(krbrlm)); fascist_cpw = 1; /* by default, enable fascist mode */ - while ((c = getopt(argc, argv, "Df:hnd:a:r:FNk:")) != EOF) + while ((c = getopt(argc, argv, "Df:hnd:a:r:FNk:")) != -1) switch(c) { case 'D': debug++; -- 2.26.2