From e3d82ebce82846d134d42eff8679be63282f5321 Mon Sep 17 00:00:00 2001 From: Mike Taylor Date: Tue, 2 Sep 2008 15:16:34 +0000 Subject: [PATCH] Route around ActivePerl brain-damage. --- SimpleServer.xs | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-) diff --git a/SimpleServer.xs b/SimpleServer.xs index 59ac45f..b838b29 100644 --- a/SimpleServer.xs +++ b/SimpleServer.xs @@ -1,5 +1,5 @@ /* - * $Id: SimpleServer.xs,v 1.82 2008-08-29 18:58:40 mike Exp $ + * $Id: SimpleServer.xs,v 1.83 2008-09-02 15:16:34 mike Exp $ * ---------------------------------------------------------------------- * * Copyright (c) 2000-2004, Index Data. @@ -1428,6 +1428,21 @@ int bend_explain(void *handle, bend_explain_rr *q) return 0; } + +/* + * You'll laugh when I tell you this ... Astonishingly, it turns out + * that ActivePerl (which is widely used on Windows) has, in the + * header file Perl\lib\CORE\XSUB.h, the following heinous crime: + * # define open PerlLIO_open + * This of course screws up the use of the "open" member of the + * Z_IdAuthentication structure below, so we have to undo this + * brain-damage. + */ +#ifdef open +#undef open +#endif + + bend_initresult *bend_init(bend_initrequest *q) { int dummy = simpleserver_clone(); -- 1.7.10.4