postgres.git / summary / log / commit / refs
commit ed47146f1e376a1dc3dbef4ea9a53cac9eebe3c6
Author: Andrew Dunstan <andrew@dunslane.net>
Date: Sun Jan 08 15:50:00 2006 +0000
First released in: 8.1.3
Stop perl from hijacking stdio and other stuff on Windows.
src/pl/plperl/SPI.xs | 6 ++++++
src/pl/plperl/plperl.c | 8 +++++++-
src/pl/plperl/spi_internal.c | 6 ++++++
3 files changed, 19 insertions(+), 1 deletion(-)
diff --git a/src/pl/plperl/SPI.xs b/src/pl/plperl/SPI.xs
index 8d14f093b72..5bcff1fc142 100644
--- a/src/pl/plperl/SPI.xs
+++ b/src/pl/plperl/SPI.xs
@@ -4,6 +4,12 @@
#undef _
/* perl stuff */
+
+/* stop perl from hijacking stdio and other stuff */
+#ifdef WIN32
+#define WIN32IO_IS_STDIO
+#endif
+
#include "EXTERN.h"
#include "perl.h"
#include "XSUB.h"
diff --git a/src/pl/plperl/plperl.c b/src/pl/plperl/plperl.c
index 935cf94d168..6a5d1546ff5 100644
--- a/src/pl/plperl/plperl.c
+++ b/src/pl/plperl/plperl.c
@@ -33,7 +33,7 @@
* ENHANCEMENTS, OR MODIFICATIONS.
*
* IDENTIFICATION
- * $PostgreSQL: pgsql/src/pl/plperl/plperl.c,v 1.94.2.1 2005/11/22 18:23:30 momjian Exp $
+ * $PostgreSQL: pgsql/src/pl/plperl/plperl.c,v 1.94.2.2 2006/01/08 15:50:00 adunstan Exp $
*
**********************************************************************/
@@ -57,6 +57,12 @@
#include "mb/pg_wchar.h"
/* perl stuff */
+
+/* stop perl from hijacking stdio and other stuff */
+#ifdef WIN32
+#define WIN32IO_IS_STDIO
+#endif
+
#include "EXTERN.h"
#include "perl.h"
#include "XSUB.h"
diff --git a/src/pl/plperl/spi_internal.c b/src/pl/plperl/spi_internal.c
index c022d7d9e57..e7f9c20f7be 100644
--- a/src/pl/plperl/spi_internal.c
+++ b/src/pl/plperl/spi_internal.c
@@ -8,6 +8,12 @@
/* Defined by Perl */
#undef _
+
+/* stop perl from hijacking stdio and other stuff */
+#ifdef WIN32
+#define WIN32IO_IS_STDIO
+#endif
+
#include "spi_internal.h"
[parent: e1926aa91e31]