Closed
Bug 676180
Opened 13 years ago
Closed 13 years ago
memory allocation / deallocation mismatch in toolkit/system/gnome/nsGIOService.cpp
Categories
(Toolkit :: General, defect)
Tracking
()
RESOLVED
FIXED
mozilla8
People
(Reporter: david.volgyes, Assigned: david.volgyes)
References
Details
(Keywords: memory-leak)
Attachments
(1 file)
876 bytes,
patch
|
karlt
:
review+
|
Details | Diff | Splinter Review |
User Agent: Mozilla/5.0 (X11; Linux x86_64; rv:5.0) Gecko/20100101 Firefox/5.0 Build ID: 20110622232440 Steps to reproduce: I run cppcheck 1.49 on the latest source, and I found several bugs. This is one of them. Actual results: Memory was allocated with strdup(), and freed with g_free. strdup uses malloc() and that causes a memory allocation/deallocation mismatch. Expected results: g_strdup should be used, as in the attached files you can see.
Updated•13 years ago
|
Product: Firefox → Toolkit
QA Contact: general → general
Updated•13 years ago
|
Attachment #550298 -
Flags: review?(karlt)
Updated•13 years ago
|
Status: UNCONFIRMED → NEW
Ever confirmed: true
Comment 1•13 years ago
|
||
Comment on attachment 550298 [details] [diff] [review] proposed solution. Thanks! In future patches can you include function names and 8 lines of context, please? Mercurial can be configured to do this automatically as in the diff section here: https://developer.mozilla.org/en/Mercurial_FAQ#How_can_I_generate_a_patch_for_somebody_else_to_check-in_for_me.3f
Attachment #550298 -
Flags: review?(karlt) → review+
Comment 2•13 years ago
|
||
http://hg.mozilla.org/integration/mozilla-inbound/rev/3a754c19cacd
Whiteboard: [inbound]
Comment 3•13 years ago
|
||
http://hg.mozilla.org/mozilla-central/rev/3a754c19cacd
Status: NEW → RESOLVED
Closed: 13 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla8
Updated•13 years ago
|
Assignee: nobody → david.volgyes
Whiteboard: [inbound]
You need to log in
before you can comment on or make changes to this bug.
Description
•