Closed
Bug 266259
Opened 20 years ago
Closed 19 years ago
memory leak in nsCharsetConverterManager::GetCharsetLangGroupRaw()
Categories
(Core :: Internationalization, defect)
Tracking
()
RESOLVED
FIXED
People
(Reporter: eagle.lu, Assigned: smontagu)
References
Details
(Keywords: memory-leak)
Attachments
(2 files)
843 bytes,
patch
|
smontagu
:
review+
neil
:
superreview+
|
Details | Diff | Splinter Review |
862 bytes,
patch
|
jshin1987
:
review+
jshin1987
:
superreview+
chofmann
:
approval-aviary1.0.5-
chofmann
:
approval-aviary1.1a1+
chofmann
:
approval1.7.8-
chofmann
:
approval1.8b2+
|
Details | Diff | Splinter Review |
Following codes fragement will cause memory leak: In nsCharsetConvertManager::GetCharsetLangGroupRaw() { ... res = GetBundleValue(mDataBundle, aCharset, NS_LITERAL_STRING(".LangGroup"), langGroup); *aResult = NS_NewAtom(langGroup); return res; } If the call GetBundleValue() fails. NS_NewAtom(langGroup) will be called. But in the following codes (in SetCharsetLangGroup()): res = gCharSetManager->GetCharsetLangGroupRaw(aCharSetInfo->mCharSet, &aCharSetInfo->mLangGroup); if (NS_FAILED(res)) { aCharSetInfo->mLangGroup = NS_NewAtom(""); if NS_FAILED(res) is true, NS_NewAtom("") will be called, which will cause the reference count of (class AtomImpl*)(aCharSetInfo->mLangGroup) to increse twice. This is incorrect.
Comment on attachment 163553 [details] [diff] [review] patch v0 Can you give r/sr? Thanks
Attachment #163553 -
Flags: superreview?(blizzard)
Attachment #163553 -
Flags: review?(smontagu)
Assignee | ||
Comment 3•20 years ago
|
||
Comment on attachment 163553 [details] [diff] [review] patch v0 r=smontagu
Attachment #163553 -
Flags: review?(smontagu) → review+
Comment 4•20 years ago
|
||
*** Bug 266386 has been marked as a duplicate of this bug. ***
Attachment #163553 -
Flags: superreview?(blizzard) → superreview?(neil.parkwaycc.co.uk)
Updated•19 years ago
|
Attachment #163553 -
Flags: superreview?(neil.parkwaycc.co.uk) → superreview+
Comment 6•19 years ago
|
||
Comment on attachment 182237 [details] [diff] [review] same patch but based on latest code base transfering r/sr and asking for a to all branches. This is a very low risk patch that gets rid of a memory leak.
Attachment #182237 -
Flags: superreview+
Attachment #182237 -
Flags: review+
Attachment #182237 -
Flags: approval1.8b2?
Attachment #182237 -
Flags: approval1.7.8?
Attachment #182237 -
Flags: approval-aviary1.1a?
Attachment #182237 -
Flags: approval-aviary1.0.4?
checked in trunk
Status: NEW → RESOLVED
Closed: 19 years ago
Resolution: --- → FIXED
Comment 8•19 years ago
|
||
urh... the tree is frozen so that you're not supposed to check in without approval.
Comment 9•19 years ago
|
||
Comment on attachment 182237 [details] [diff] [review] same patch but based on latest code base a=chofmann for trunk only. this will get the fix in 1.1a and 1.8b2. we are only taking critical security fixes on the branches
Attachment #182237 -
Flags: approval1.8b2?
Attachment #182237 -
Flags: approval1.8b2+
Attachment #182237 -
Flags: approval1.7.8?
Attachment #182237 -
Flags: approval1.7.8-
Attachment #182237 -
Flags: approval-aviary1.1a?
Attachment #182237 -
Flags: approval-aviary1.1a+
Attachment #182237 -
Flags: approval-aviary1.0.4?
Attachment #182237 -
Flags: approval-aviary1.0.4-
You need to log in
before you can comment on or make changes to this bug.
Description
•