[Bug 858966] New: perl-5.16: my variables with attributes leak

bugzilla at redhat.com bugzilla at redhat.com
Thu Sep 20 08:17:00 UTC 2012


https://bugzilla.redhat.com/show_bug.cgi?id=858966

            Bug ID: 858966
        QA Contact: extras-qa at fedoraproject.org
          Severity: unspecified
               URL: https://rt.perl.org/rt3//Public/Bug/Display.html?id=11
                    4764
           Version: 18
          Priority: unspecified
                CC: cweyl at alumni.drew.edu, iarnell at gmail.com,
                    jplesnik at redhat.com, kasal at ucw.cz, lkundrak at v3.sk,
                    mmaslano at redhat.com,
                    perl-devel at lists.fedoraproject.org, ppisar at redhat.com,
                    psabata at redhat.com, rc040203 at freenet.de,
                    tcallawa at redhat.com
          Assignee: mmaslano at redhat.com
           Summary: perl-5.16: my variables with attributes leak
        Regression: ---
      Story Points: ---
    Classification: Fedora
                OS: Unspecified
          Reporter: ppisar at redhat.com
              Type: Bug
     Documentation: ---
          Hardware: Unspecified
        Mount Type: ---
            Status: ASSIGNED
         Component: perl
           Product: Fedora

This code consumes more and more memory:

$ perl -e 'while (1) { eval qq{my $x : shared}; }'

perl-5.16 (F≥18) is affected.

Fixes by upstream commit:

commit 9fa29fa7929b4167c5491b792c5cc7e4365a2839
Author: Father Chrysostomos <sprout at cpan.org>
Date:   Wed Sep 19 21:53:51 2012 -0700

    [perl #114764] Stop my vars with attrs from leaking

    S_apply_attrs was creating a SV containing a stash name, that was
    later to be put in a const op, which would take care of freeing it.
    But it didn’t free it for a my variable, because the branch where that
    const op was created didn’t apply.  So move the creation of that SV
    inside the branch that uses it, otherwise it leaks.  This leak was the
    result of commit 95f0a2f1ffc6.

-- 
You are receiving this mail because:
You are on the CC list for the bug.


More information about the perl-devel mailing list