Skip to content

Commit ffda674

Browse files
committed
Tweak pgbench.c to remove the hidden assumption that a WIN32 machine
couldn't possibly HAVE_GETOPT. I believe this is the most appropriate form of the patch submitted 2007-08-07 by Hiroshi Saito, though not having a Windows build environment I won't know for sure till I see the buildfarm results.
1 parent 314ed5d commit ffda674

File tree

1 file changed

+3
-7
lines changed

1 file changed

+3
-7
lines changed

contrib/pgbench/pgbench.c

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* $PostgreSQL: pgsql/contrib/pgbench/pgbench.c,v 1.71 2007/08/25 09:21:14 ishii Exp $
2+
* $PostgreSQL: pgsql/contrib/pgbench/pgbench.c,v 1.72 2007/09/27 20:39:43 tgl Exp $
33
*
44
* pgbench: a simple benchmark program for PostgreSQL
55
* written by Tatsuo Ishii
@@ -24,10 +24,11 @@
2424
#include <ctype.h>
2525

2626
#ifdef WIN32
27-
#include "win32.h"
27+
#include <win32.h>
2828
#else
2929
#include <sys/time.h>
3030
#include <unistd.h>
31+
#endif /* ! WIN32 */
3132

3233
#ifdef HAVE_GETOPT_H
3334
#include <getopt.h>
@@ -40,15 +41,10 @@
4041
#ifdef HAVE_SYS_RESOURCE_H
4142
#include <sys/resource.h> /* for getrlimit */
4243
#endif
43-
#endif /* ! WIN32 */
4444

4545
extern char *optarg;
4646
extern int optind;
4747

48-
#ifdef WIN32
49-
#undef select
50-
#endif
51-
5248

5349
/********************************************************************
5450
* some configurable parameters */

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy