From: Dave Mitchell Date: Sun, 24 Mar 2002 22:23:08 +0000 (+0000) Subject: pack('w') 64-bit buffer overflow X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=7c1b502b4c535da3880ace9c4878c1d14e7b98fd;p=p5sagit%2Fp5-mst-13.2.git pack('w') 64-bit buffer overflow Message-ID: <20020324222308.B21963@fdgroup.com> p4raw-id: //depot/perl@15478 --- diff --git a/pp_pack.c b/pp_pack.c index 7df5f45..67f53e7 100644 --- a/pp_pack.c +++ b/pp_pack.c @@ -2176,7 +2176,7 @@ Perl_pack_cat(pTHX_ SV *cat, char *pat, register char *patend, register SV **beg against UV_MAX_P1. */ if (SvIOK(fromstr) || adouble < UV_MAX_P1) { - char buf[1 + sizeof(UV)]; + char buf[(sizeof(UV)*8)/7+1]; char *in = buf + sizeof(buf); UV auv = SvUV(fromstr);