projects
/
users
/
c2main
/
postgres.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
76dd09b
)
Give getopt() a prototype and modern style arg specs.
author
Andrew Dunstan
<
[email protected]
>
Mon, 25 Apr 2011 16:38:10 +0000
(12:38 -0400)
committer
Andrew Dunstan
<
[email protected]
>
Mon, 25 Apr 2011 16:38:10 +0000
(12:38 -0400)
Welcome to the 1990s.
src/port/getopt.c
patch
|
blob
|
blame
|
history
diff --git
a/src/port/getopt.c
b/src/port/getopt.c
index aacfbc3e540e91354da0802edb82fcadc51fe0b9..e901bf7db50f0d1efc7690ac51a1b160217b4e41 100644
(file)
--- a/
src/port/getopt.c
+++ b/
src/port/getopt.c
@@
-61,6
+61,8
@@
extern char *optarg;
#define BADARG (int)':'
#define EMSG ""
+int getopt(int nargc, char *const * nargv, const char * ostr);
+
/*
* getopt
* Parse argc/argv argument vector.
@@
-72,10
+74,7
@@
extern char *optarg;
* returning -1.)
*/
int
-getopt(nargc, nargv, ostr)
-int nargc;
-char *const * nargv;
-const char *ostr;
+getopt(int nargc, char *const * nargv, const char * ostr)
{
static char *place = EMSG; /* option letter processing */
char *oli; /* option letter list index */