Closed
Bug 306809
Opened 20 years ago
Closed 20 years ago
oom mlk in txVariable::Convert
Categories
(Core :: XSLT, defect, P1)
Tracking
()
RESOLVED
FIXED
mozilla1.8beta4
People
(Reporter: timeless, Assigned: peterv)
References
()
Details
(Keywords: fixed1.8, memory-leak)
Attachments
(1 file)
1.54 KB,
patch
|
bzbarsky
:
review+
bzbarsky
:
superreview+
asa
:
approval1.8b4+
|
Details | Diff | Splinter Review |
first the easy mlk:
1108 txXPathNode *xpathNode =
1109 txXPathNativeNode::createXPathNode(node);
1110 if (!xpathNode) {
1111 return NS_ERROR_FAILURE;
1112 peterv 1.39 }
1113
1114 nodeSet->add(*xpathNode);
add returns nsresult (NS_ERROR_OUT_OF_MEMORY). you leak xpathNode;
this also happens near 1202.
i think there's a more fun crash case that could happen involving spidermonkey,
but i'm not sure about the rules for js dependent strings (if i'm right, you
could try to construct a dependentstring from a null pointer or a fmr length).
Assignee | ||
Comment 1•20 years ago
|
||
Attachment #194673 -
Flags: superreview?(bzbarsky)
Attachment #194673 -
Flags: review?(bzbarsky)
![]() |
||
Comment 2•20 years ago
|
||
Comment on attachment 194673 [details] [diff] [review]
v1
I'm assuming add() just copies the data in the node and doesn't hold a ptr to
it, right?
Attachment #194673 -
Flags: superreview?(bzbarsky)
Attachment #194673 -
Flags: superreview+
Attachment #194673 -
Flags: review?(bzbarsky)
Attachment #194673 -
Flags: review+
Assignee | ||
Comment 3•20 years ago
|
||
Yes. We're going to clean up the whole txXPathNativeNode mess at some point so
that we won't run into these leaks anymore.
Status: NEW → ASSIGNED
Priority: -- → P1
Target Milestone: --- → mozilla1.8beta4
Assignee | ||
Updated•20 years ago
|
Status: ASSIGNED → RESOLVED
Closed: 20 years ago
Resolution: --- → FIXED
Assignee | ||
Comment 4•20 years ago
|
||
Comment on attachment 194673 [details] [diff] [review]
v1
Trivial leak fix.
Attachment #194673 -
Flags: approval1.8b4?
Updated•20 years ago
|
Attachment #194673 -
Flags: approval1.8b4? → approval1.8b4+
Comment 5•20 years ago
|
||
Time is short for 1.8b4. If this isn't landed today, it's not going to make the
train.
You need to log in
before you can comment on or make changes to this bug.
Description
•