Closed
Bug 1268449
Opened 9 years ago
Closed 9 years ago
[Static Analysis][Resource leak] In function Resolve from ice_unittest.cpp
Categories
(Core :: WebRTC: Networking, defect, P3)
Core
WebRTC: Networking
Tracking
()
RESOLVED
FIXED
mozilla49
Tracking | Status | |
---|---|---|
firefox49 | --- | fixed |
People
(Reporter: andi, Assigned: andi)
References
(Blocks 1 open bug)
Details
(Keywords: coverity, Whiteboard: CID 1358788 )
Attachments
(1 file)
The Static Analysis tool Coverity added that variable |res| leaks memory in several places:
1.
>> default:
>> std::cerr << "Got unexpected address family in DNS lookup: "
>> << res->ai_family << std::endl;
>> return "";
2.
>> if (!strlen(str_addr)) {
>> std::cerr << "inet_ntop failed" << std::endl;
>> }
>>
>> return str_addr;
In both cases we should call freeaddrinfo
Assignee | ||
Comment 1•9 years ago
|
||
Review commit: https://reviewboard.mozilla.org/r/49441/diff/#index_header
See other reviews: https://reviewboard.mozilla.org/r/49441/
Attachment #8746490 -
Flags: review?(ekr)
Comment 2•9 years ago
|
||
Comment on attachment 8746490 [details]
MozReview Request: Bug 1268449 - prevent memory leak in Resolve. r?ekr
https://reviewboard.mozilla.org/r/49441/#review46309
LGTM
Attachment #8746490 -
Flags: review?(ekr) → review+
Updated•9 years ago
|
Rank: 35
Priority: -- → P3
Comment 4•9 years ago
|
||
bugherder |
Status: NEW → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla49
You need to log in
before you can comment on or make changes to this bug.
Description
•