Use an integer rather than a char for the getopt() return value in main()

in order to make it work with architectures that use unsigned chars.
This commit is contained in:
mark 1997-01-29 01:29:09 +00:00
parent c4062005b4
commit 2ab96deb9a
2 changed files with 4 additions and 4 deletions

View File

@ -39,7 +39,7 @@ extern char *index();
#if !defined(lint) && defined(LIBC_SCCS)
static char sccsid[] = "@(#)ipf.c 1.23 6/5/96 (C) 1993-1995 Darren Reed";
static char rcsid[] = "$Id: ipf.c,v 1.1.1.1 1997/01/05 13:06:38 mrg Exp $";
static char rcsid[] = "$Id: ipf.c,v 1.2 1997/01/29 01:29:09 mark Exp $";
#endif
#if SOLARIS
@ -61,7 +61,7 @@ int main(argc,argv)
int argc;
char *argv[];
{
char c;
int c;
while ((c = getopt(argc, argv, "AdDEf:F:Il:noprsUvyzZ")) != -1) {
switch (c)

View File

@ -39,7 +39,7 @@ extern char *index();
#if !defined(lint) && defined(LIBC_SCCS)
static char sccsid[] = "@(#)ipf.c 1.23 6/5/96 (C) 1993-1995 Darren Reed";
static char rcsid[] = "$Id: ipf.c,v 1.1.1.1 1997/01/05 13:06:38 mrg Exp $";
static char rcsid[] = "$Id: ipf.c,v 1.2 1997/01/29 01:29:09 mark Exp $";
#endif
#if SOLARIS
@ -61,7 +61,7 @@ int main(argc,argv)
int argc;
char *argv[];
{
char c;
int c;
while ((c = getopt(argc, argv, "AdDEf:F:Il:noprsUvyzZ")) != -1) {
switch (c)