On Thu, Dec 01, 2005 at 07:45:48AM -0800, Jan Dubois wrote: > On Thu, 01 Dec 2005, Gisle Aas wrote: > > > > This patch plugs that hole. > > PL_memory_wrap is only defined if you have PERL_MALLOC_WRAP enabled, > so you need to check for it: > > > > --- perl-current/sv.c 2005-12-01 10:56:34.000000000 +0100 > > +++ perl-hack/sv.c 2005-12-01 15:15:01.000000000 +0100 > > @@ -8889,6 +8889,8 @@ > > > > /* calculate width before utf8_upgrade changes it */ > > have = esignlen + zeros + elen; > > #ifdef PERL_MALLOC_WRAP > > > + if (have < zeros) > > + Perl_croak_nocontext(PL_memory_wrap); > > #endif Alternatively change it so that PL_memory_wrap always be defined? I believe that the new test here will work on all platforms, even those where the generic memory wrap macros don't. Nicholas ClarkThread Previous | Thread Next