repo: rxvt-unicode-sixel
action: commit
revision: 
path_from: 
revision_from: 095624561a75e467b981556ee0b4576fcefdde5e:
path_to: 
revision_to: 
git.thebackupbox.net
rxvt-unicode-sixel
git clone git://git.thebackupbox.net/rxvt-unicode-sixel
commit 095624561a75e467b981556ee0b4576fcefdde5e
Author: Emanuele Giaquinta 
Date:   Fri Mar 1 09:33:51 2013 +0000

    Remove hack.

diff --git a/src/rxvtperl.xs b/src/rxvtperl.xs
index 3f808ff6fc9a658e3eb947b7445a69e323fff897..
index ..ce28ad9711ff832840570cde063082a5715a1487 100644
--- a/src/rxvtperl.xs
+++ b/src/rxvtperl.xs
@@ -2399,20 +2399,18 @@ rxvt_img::filter (octet_string name, SV *params = &PL_sv_undef)

         if (SvOK (params))
 	  {
-            // we overlay rxvt_temp_buf, what a hack
-            assert (sizeof (rxvt_img::nv) >= sizeof (int));
-
             if (!SvROK (params) || SvTYPE (SvRV (params)) != SVt_PVAV)
               croak ("rxvt_img::filter: params must be an array reference with parameter values");

             nparams = av_len ((AV *)SvRV (params)) + 1;
-            vparams = rxvt_temp_buf (nparams);
+            vparams = (rxvt_img::nv *)malloc (nparams * sizeof (rxvt_img::nv));

             for (int i = 0; i < nparams; ++i)
               vparams [i] = SvNV (*av_fetch ((AV *)SvRV (params), i, 1));
           }

         RETVAL = THIS->filter (name, nparams, vparams);
+        free (vparams);
 	OUTPUT:
         RETVAL

-----END OF PAGE-----