diff options
Diffstat (limited to 'src/backend')
-rw-r--r-- | src/backend/postmaster/postmaster.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/backend/postmaster/postmaster.c b/src/backend/postmaster/postmaster.c index 21ed2eaf669..6148f286636 100644 --- a/src/backend/postmaster/postmaster.c +++ b/src/backend/postmaster/postmaster.c @@ -232,7 +232,8 @@ extern char *optarg; extern int optind, opterr; -#ifdef HAVE_INT_OPTRESET +/* If not HAVE_GETOPT, we are using src/port/getopt.c, which has optreset */ +#if defined(HAVE_INT_OPTRESET) || !defined(HAVE_GETOPT) extern int optreset; #endif @@ -658,7 +659,7 @@ PostmasterMain(int argc, char *argv[]) * getopt(3) library so that it will work correctly in subprocesses. */ optind = 1; -#ifdef HAVE_INT_OPTRESET +#if defined(HAVE_INT_OPTRESET) || !defined(HAVE_GETOPT) optreset = 1; /* some systems need this too */ #endif |