[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Pre-approval for perl/5.10.0-17



On Fri, Oct 31, 2008 at 08:45:59PM +0100, Marc 'HE' Brockschmidt wrote:
> Niko Tyni <ntyni@debian.org> writes:
> >  perl (5.10.0-17) unstable; urgency=low
> [...]
> > Please ack/nack, see the attached (filtered) debdiff for the patches. 
> 
> ACK. Sorry for the delay.

No problem, thanks.

Got the attached two more patches in between, please ack/nack these as well.
See #503975.
-- 
Niko Tyni   ntyni@debian.org
Fix memory leak in // caused by single-char character class optimization. (See #503975)

Blead change 34507:

Fix memory leak in // caused by single-char character class
optimization. This was most probably introduced with #28262.
This change fixes perl #59516.

p4raw-id: //depot/perl@34507
diff --git a/regcomp.c b/regcomp.c
index 5a175ba..9e6bb7b 100644
--- a/regcomp.c
+++ b/regcomp.c
@@ -8239,6 +8239,9 @@ parseit:
         *STRING(ret)= (char)value;
         STR_LEN(ret)= 1;
         RExC_emit += STR_SZ(1);
+	if (listsv) {
+	    SvREFCNT_dec(listsv);
+	}
         return ret;
     }
     /* optimize case-insensitive simple patterns (e.g. /[a-z]/i) */
Fix memory leak with qr//. (Closes: #503975)

Adapted from upstream change 34506.
diff --git a/pp_hot.c b/pp_hot.c
index 57fa328..4a4e9e8 100644
--- a/pp_hot.c
+++ b/pp_hot.c
@@ -1198,6 +1198,9 @@ PP(pp_qr)
     if (rx->extflags & RXf_TAINTED)
         SvTAINTED_on(rv);
     sv_magic(sv,(SV*)ReREFCNT_inc(rx), PERL_MAGIC_qr,0,0);
+    if (pkg) {
+	SvREFCNT_dec(pkg);
+    }
     XPUSHs(rv);
     RETURN;
 }

Reply to: