Bug 767597 - Memory leak with non-matching named captures
Summary: Memory leak with non-matching named captures
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: perl
Version: 16
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Petr Pisar
QA Contact: Fedora Extras Quality Assurance
URL: https://rt.perl.org/rt3/Public/Bug/Di...
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2011-12-14 13:21 UTC by Petr Pisar
Modified: 2012-01-07 22:57 UTC (History)
7 users (show)

Fixed In Version: perl-5.14.2-193.fc16
Doc Type: Bug Fix
Doc Text:
Clone Of:
: 767608 (view as bug list)
Environment:
Last Closed: 2012-01-02 21:50:38 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)
Fix ported for perl-5.14.2 (1.91 KB, patch)
2011-12-14 14:25 UTC, Petr Pisar
no flags Details | Diff

Description Petr Pisar 2011-12-14 13:21:38 UTC
Referring non-matched named capture leaks memory:

for (1..10_000_000) {
  if ("foo" =~ /(foo|(?<capture>bar))?/) {
    my $capture = $+{capture}
  }
}


This is tracked by upstream (https://rt.perl.org/rt3/Public/Bug/Display.html?id=78266) and fixed by commit 7402016d87474403eea5c52dc2c071f68cbbe25c.

Comment 1 Petr Pisar 2011-12-14 13:36:02 UTC
F17 (perl-5.14.2-205.fc17.x86_64) affected.
F16 (perl-5.14.2-191.fc16.x86_64) affected.
F15 (perl-5.12.4-163.fc15.x86_64) affected.

Comment 2 Petr Pisar 2011-12-14 14:25:45 UTC
Created attachment 546750 [details]
Fix ported for perl-5.14.2

Comment 3 Fedora Update System 2011-12-14 17:53:55 UTC
perl-5.14.2-192.fc16 has been submitted as an update for Fedora 16.
https://admin.fedoraproject.org/updates/perl-5.14.2-192.fc16

Comment 4 Fedora Update System 2011-12-14 17:55:17 UTC
perl-5.12.4-164.fc15 has been submitted as an update for Fedora 15.
https://admin.fedoraproject.org/updates/perl-5.12.4-164.fc15

Comment 5 Fedora Update System 2011-12-14 23:29:05 UTC
Package perl-5.14.2-192.fc16:
* should fix your issue,
* was pushed to the Fedora 16 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing perl-5.14.2-192.fc16'
as soon as you are able to.
Please go to the following url:
https://admin.fedoraproject.org/updates/FEDORA-2011-17088/perl-5.14.2-192.fc16
then log in and leave karma (feedback).

Comment 6 Fedora Update System 2011-12-21 13:08:02 UTC
perl-5.14.2-193.fc16 has been submitted as an update for Fedora 16.
https://admin.fedoraproject.org/updates/perl-5.14.2-193.fc16

Comment 7 Fedora Update System 2012-01-02 21:50:38 UTC
perl-5.12.4-164.fc15 has been pushed to the Fedora 15 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 8 Fedora Update System 2012-01-07 22:57:15 UTC
perl-5.14.2-193.fc16 has been pushed to the Fedora 16 stable repository.  If problems still persist, please make note of it in this bug report.


Note You need to log in before you can comment on or make changes to this bug.