aboutsummaryrefslogtreecommitdiff
path: root/src/interfaces/ecpg/ecpglib/ecpglib_extern.h
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2019-01-21 16:17:10 -0500
committerTom Lane <tgl@sss.pgh.pa.us>2019-01-21 16:17:10 -0500
commitee27584c4a40620fb26d1729e9cc449d54d62b07 (patch)
treee841f04f0e7ca473503f6dc52b1bf53a3c8c2f4b /src/interfaces/ecpg/ecpglib/ecpglib_extern.h
parent527114e51e45dbd91d46171fa4a111355f0dfc3b (diff)
downloadpostgresql-ee27584c4a40620fb26d1729e9cc449d54d62b07.tar.gz
postgresql-ee27584c4a40620fb26d1729e9cc449d54d62b07.zip
Second try at fixing ecpglib thread-safety problem.
While Windows (allegedly) has _configthreadlocale() pretty far back, it seems MinGW didn't acquire support for that till more recently. Fortunately, we can use an autoconf probe on that toolchain, instead of guessing whether it's there. (Hm, I wonder whether Cygwin will need this also.) Per buildfarm. Discussion: https://postgr.es/m/20190121193512.tdmcnic2yjxlufaw@alap3.anarazel.de
Diffstat (limited to 'src/interfaces/ecpg/ecpglib/ecpglib_extern.h')
-rw-r--r--src/interfaces/ecpg/ecpglib/ecpglib_extern.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/interfaces/ecpg/ecpglib/ecpglib_extern.h b/src/interfaces/ecpg/ecpglib/ecpglib_extern.h
index 41851d59007..ae2dcfc6172 100644
--- a/src/interfaces/ecpg/ecpglib/ecpglib_extern.h
+++ b/src/interfaces/ecpg/ecpglib/ecpglib_extern.h
@@ -69,7 +69,7 @@ struct statement
locale_t oldlocale;
#else
char *oldlocale;
-#ifdef WIN32
+#ifdef HAVE__CONFIGTHREADLOCALE
int oldthreadlocale;
#endif
#endif