]> git.imager.perl.org - imager.git/commitdiff
fix C89 and non-threaded builds
authorTony Cook <tony@develop-help.com>
Mon, 13 Aug 2012 09:02:17 +0000 (19:02 +1000)
committerTony Cook <tony@develop-help.com>
Tue, 14 Aug 2012 09:58:20 +0000 (19:58 +1000)
Imager.xs

index 13b53532017721367d4428ed1903f3dfa2563f56..58775f4a657ac53c7e1f60ad0e606ba43b51ee0b 100644 (file)
--- a/Imager.xs
+++ b/Imager.xs
@@ -4062,8 +4062,8 @@ im_context_DESTROY(ctx)
 void
 im_context_CLONE(...)
     CODE:
-      (void)items;
       MY_CXT_CLONE;
+      (void)items;
       /* the following sv_setref_pv() will free this inc */
       im_context_refinc(MY_CXT.ctx, "CLONE");
       MY_CXT.ctx = im_context_clone(MY_CXT.ctx, "CLONE");
@@ -4074,9 +4074,11 @@ im_context_CLONE(...)
 BOOT:
         PERL_SET_GLOBAL_CALLBACKS;
        PERL_PL_SET_GLOBAL_CALLBACKS;
+#ifdef PERL_IMPLICIT_CONTEXT
        {
           MY_CXT_INIT;
          (void)MY_CXT;
        }
+#endif
        start_context(aTHX);
        im_get_context = perl_get_context;