From: millert Date: Mon, 20 Jan 1997 17:19:31 +0000 (+0000) Subject: getopt returns -1 not EOF! X-Git-Url: http://artulab.com/gitweb/?a=commitdiff_plain;h=ddfa4c2e571313ab168586eba6d79ea0aa67c26f;p=openbsd getopt returns -1 not EOF! --- diff --git a/share/misc/getopt b/share/misc/getopt index b5ec0e43b11..e26ed541cdb 100644 --- a/share/misc/getopt +++ b/share/misc/getopt @@ -2,7 +2,7 @@ * Main/getopt(3) fragment. * * from: @(#)getopt 5.3 (Berkeley) 3/28/94 - * $Id: getopt,v 1.1.1.1 1995/10/18 08:44:44 deraadt Exp $ + * $Id: getopt,v 1.2 1997/01/20 17:19:31 millert Exp $ */ #include @@ -18,7 +18,7 @@ main(argc, argv) { int ch; - while ((ch = getopt(argc, argv, "")) != EOF) + while ((ch = getopt(argc, argv, "")) != -1) switch (ch) { case '': break;