mirror of
https://github.com/postgres/postgres.git
synced 2025-06-06 00:02:36 -04:00
Silence warnings about redefining popen on Mingw-w64.
Mingw-w64 headers map popen/pclose to _popen and _pclose, but we want to use our popen wrapper rather than the Mingw-w64. #undef the Mingw's version.
This commit is contained in:
parent
4773c70aa4
commit
a82a17475d
@ -301,6 +301,18 @@ extern FILE *pgwin32_fopen(const char *, const char *);
|
|||||||
#define fopen(a,b) pgwin32_fopen(a,b)
|
#define fopen(a,b) pgwin32_fopen(a,b)
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Mingw-w64 headers #define popen and pclose to _popen and _pclose. We want
|
||||||
|
* to use our popen wrapper, rather than plain _popen, so override that. For
|
||||||
|
* consistency, use our version of pclose, too.
|
||||||
|
*/
|
||||||
|
#ifdef popen
|
||||||
|
#undef popen
|
||||||
|
#endif
|
||||||
|
#ifdef pclose
|
||||||
|
#undef pclose
|
||||||
|
#endif
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* system() and popen() replacements to enclose the command in an extra
|
* system() and popen() replacements to enclose the command in an extra
|
||||||
* pair of quotes.
|
* pair of quotes.
|
||||||
|
Loading…
x
Reference in New Issue
Block a user