WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
55156
PatternAlternative leaked in YarrPatternConstructor::atomParenthesesEnd()
https://bugs.webkit.org/show_bug.cgi?id=55156
Summary
PatternAlternative leaked in YarrPatternConstructor::atomParenthesesEnd()
Michael Saboff
Reported
2011-02-24 09:23:58 PST
The removal of empty disjunction alternatives from the alternatives vector doesn't delete the removed alternative thus leaking it.
Attachments
Patch to delete unneeded PatternAlternative
(1.46 KB, patch)
2011-02-24 11:06 PST
,
Michael Saboff
oliver
: review+
Details
Formatted Diff
Diff
View All
Add attachment
proposed patch, testcase, etc.
Michael Saboff
Comment 1
2011-02-24 11:06:30 PST
Created
attachment 83682
[details]
Patch to delete unneeded PatternAlternative
Oliver Hunt
Comment 2
2011-02-24 11:19:23 PST
Comment on
attachment 83682
[details]
Patch to delete unneeded PatternAlternative r=me
Michael Saboff
Comment 3
2011-02-24 11:25:56 PST
Committed
r79594
: <
http://trac.webkit.org/changeset/79594
>
Darin Adler
Comment 4
2011-02-24 11:58:14 PST
Comment on
attachment 83682
[details]
Patch to delete unneeded PatternAlternative View in context:
https://bugs.webkit.org/attachment.cgi?id=83682&action=review
> Source/JavaScriptCore/yarr/YarrPattern.cpp:500 > + PatternAlternative* altToRemove = parenthesesDisjunction->m_alternatives[i]; > parenthesesDisjunction->m_alternatives.remove(i); > + delete altToRemove;
A couple post-patch-lading thoughts: I would prefer to do this with OwnPtr instead of an explicit delete. Maybe m_alternatives could actually use OwnPtr. I would also have called it alternativeToRemove instead of altToRemove.
WebKit Review Bot
Comment 5
2011-02-24 15:59:25 PST
http://trac.webkit.org/changeset/79594
might have broken GTK Linux 32-bit Release
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug