From: Vincent Pit Date: Sat, 24 Apr 2010 13:05:22 +0000 (+0200) Subject: MY_CXT_INIT can be a declaration, so put it in a block to be strictly conformant... X-Git-Tag: rt57699~3 X-Git-Url: http://git.vpit.fr/?a=commitdiff_plain;h=7328cc91a653de36dc35a3972821f77db9e1ca73;p=perl%2Fmodules%2Findirect.git MY_CXT_INIT can be a declaration, so put it in a block to be strictly conformant to C89 Thanks Jan Dubois for reporting. --- diff --git a/indirect.xs b/indirect.xs index f0c42ef..f0af0b6 100644 --- a/indirect.xs +++ b/indirect.xs @@ -840,13 +840,15 @@ STATIC void indirect_setup(pTHX) { if (indirect_initialized) return; - MY_CXT_INIT; + { + MY_CXT_INIT; #if I_THREADSAFE - MY_CXT.tbl = ptable_new(); - MY_CXT.owner = aTHX; + MY_CXT.tbl = ptable_new(); + MY_CXT.owner = aTHX; #endif - MY_CXT.map = ptable_new(); - MY_CXT.linestr = NULL; + MY_CXT.map = ptable_new(); + MY_CXT.linestr = NULL; + } indirect_old_ck_const = PL_check[OP_CONST]; PL_check[OP_CONST] = MEMBER_TO_FPTR(indirect_ck_const);