Closed
Bug 317708
Opened 19 years ago
Closed 19 years ago
cairo renderer leaks memory and uses uninitialised variables with text in SVG
Categories
(Core :: SVG, defect)
Core
SVG
Tracking
()
RESOLVED
FIXED
People
(Reporter: longsonr, Unassigned)
Details
(Keywords: memory-leak)
Attachments
(2 files)
5.33 KB,
patch
|
tor
:
review+
jst
:
superreview+
|
Details | Diff | Splinter Review |
5.42 KB,
patch
|
roc
:
review+
roc
:
superreview+
|
Details | Diff | Splinter Review |
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9a1) Gecko/20051124 Firefox/1.6a1
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9a1) Gecko/20051124 Firefox/1.6a1
nsSVGCairoGlyphGeometry::Render and
nsSVGCairoGlyphGeometry::GetBoundingBox
both contain two calls to Source->GetCharacterPosition. Memory allocated in the first call is never freed.
Also it looks like if GetCharacterPosition returns a non null result then we should not call mSource->GetX or GetX as these functions return uninitialised values in this case (the individual textPath positions being encoded in the GetCharacterPosition data).
Reproducible: Always
Steps to Reproduce:
1. Display an SVG file which contains text or textPath elements
does not affect 1.5 branch.
Reporter | ||
Comment 1•19 years ago
|
||
Attachment #204136 -
Flags: review?(tor)
Updated•19 years ago
|
Status: UNCONFIRMED → NEW
Ever confirmed: true
Attachment #204136 -
Flags: review?(tor) → review+
Reporter | ||
Updated•19 years ago
|
Attachment #204136 -
Flags: superreview?(jst)
Comment 2•19 years ago
|
||
Comment on attachment 204136 [details] [diff] [review]
remove extraneous function calls and only call GetX/Y if cp is null
sr=jst
Attachment #204136 -
Flags: superreview?(jst) → superreview+
Checked in for Robert.
Status: NEW → RESOLVED
Closed: 19 years ago
Resolution: --- → FIXED
Updated•19 years ago
|
Attachment #215293 -
Flags: superreview?
Attachment #215293 -
Flags: review?(longsonr)
Attachment #215293 -
Flags: superreview? → superreview?(roc)
Comment on attachment 215293 [details] [diff] [review]
merge to branch
Really, we should be using nsAutoPtr for cp.
Attachment #215293 -
Flags: superreview?(roc)
Attachment #215293 -
Flags: superreview+
Attachment #215293 -
Flags: review?(longsonr)
Attachment #215293 -
Flags: review+
You need to log in
before you can comment on or make changes to this bug.
Description
•