Skip to content

Commit ca5a75f

Browse files
committed
Silence compiler warning about casting HANDLE to long on WIN64.
1 parent a7cb69a commit ca5a75f

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

src/test/regress/pg_regress.c

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2277,8 +2277,14 @@ regression_main(int argc, char *argv[], init_function ifunc, test_function tfunc
22772277

22782278
postmaster_running = true;
22792279

2280+
#ifdef WIN64
2281+
/* need a series of two casts to convert HANDLE without compiler warning */
2282+
#define ULONGPID(x) (unsigned long) (unsigned long long) (x)
2283+
#else
2284+
#define ULONGPID(x) (unsigned long) (x)
2285+
#endif
22802286
printf(_("running on port %d with pid %lu\n"),
2281-
port, (unsigned long) postmaster_pid);
2287+
port, ULONGPID(postmaster_pid));
22822288
}
22832289
else
22842290
{

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