]> granicus.if.org Git - postgresql/commitdiff
Unbreak isolationtester on Win32
authorAlvaro Herrera <alvherre@alvh.no-ip.org>
Fri, 4 Nov 2011 01:54:58 +0000 (23:54 -0200)
committerAlvaro Herrera <alvherre@alvh.no-ip.org>
Fri, 4 Nov 2011 02:33:48 +0000 (00:33 -0200)
I broke it in a previous commit because I neglected to install the
necessary incantations to have getopt() work on Windows.

Per red blots in buildfarm.

src/test/isolation/isolationtester.c

index 822739ec3bb4fcff666dfe3f0f8d89301c7cb9de..38f1e78dc5cab7d7d42762fb29b0365565269d0d 100644 (file)
 #ifndef WIN32
 #include <sys/time.h>
 #include <unistd.h>
+
+#ifdef HAVE_GETOPT_H
+#include <getopt.h>
+#endif
+
+#else
+int                    getopt(int argc, char *const argv[], const char *optstring);
 #endif   /* ! WIN32 */
 
 #ifdef HAVE_SYS_SELECT_H
@@ -25,6 +32,8 @@
 
 #include "isolationtester.h"
 
+extern int     optind;
+
 #define PREP_WAITING "isolationtester_waiting"
 
 /*