1
0
mirror of https://github.com/nmap/nmap.git synced 2025-12-29 10:59:02 +00:00

Update included libpcap to 1.10.1

This commit is contained in:
dmiller
2022-08-31 18:39:55 +00:00
parent 04bcefd3e4
commit 65410fead1
174 changed files with 20680 additions and 14646 deletions

View File

@@ -80,9 +80,18 @@ getopt(int nargc, char * const *nargv, const char *ostr)
place = EMSG;
return (-1);
}
} /* option letter okay? */
if ((optopt = (int)*place++) == (int)':' ||
!(oli = strchr(ostr, optopt))) {
}
optopt = (int)*place++;
if (optopt == (int)':') { /* option letter okay? */
if (!*place)
++optind;
if (opterr && *ostr != ':')
(void)fprintf(stderr,
"%s: illegal option -- %c\n", __progname, optopt);
return (BADCH);
}
oli = strchr(ostr, optopt);
if (!oli) {
/*
* if the user didn't specify '-' as an option,
* assume it means -1.
@@ -114,7 +123,7 @@ getopt(int nargc, char * const *nargv, const char *ostr)
__progname, optopt);
return (BADCH);
}
else /* white space */
else /* white space */
optarg = nargv[optind];
place = EMSG;
++optind;