If you think a bug might affect users in the 57 release, please set the correct tracking and status flags for Release Management.

[Static Analysis][Resource leak] In function GetManifestContents

RESOLVED DUPLICATE of bug 1247217

Status

()

Toolkit
Application Update
RESOLVED DUPLICATE of bug 1247217
2 years ago
2 years ago

People

(Reporter: andi, Assigned: andi)

Tracking

(Blocks: 1 bug, {coverity})

Firefox Tracking Flags

(Not tracked)

Details

(Whiteboard: CID 749520)

MozReview Requests

()

Submitter Diff Changes Open Issues Last Updated
Loading...
Error loading review requests:

Attachments

(1 attachment)

(Assignee)

Description

2 years ago
The Static Analysis tool Coverity added that in the following context if if is evaluated to true mbuf leaks:

>>    const size_t count = mmin(SSIZE_MAX, r);
>>    size_t c = fread(rb, 1, count, mfile);
>>    if (c != count) {
>>      LOG(("GetManifestContents: error reading manifest file: " LOG_S, manifest));
>>      return nullptr;
    }
(Assignee)

Comment 1

2 years ago
Created attachment 8718810 [details]
MozReview Request: Bug 1247922 - free mbuf even if something wrong happened during fread. r?netzen

Review commit: https://reviewboard.mozilla.org/r/34755/diff/#index_header
See other reviews: https://reviewboard.mozilla.org/r/34755/
Status: NEW → RESOLVED
Last Resolved: 2 years ago
Resolution: --- → DUPLICATE
Duplicate of bug: 1247217
You need to log in before you can comment on or make changes to this bug.