Closed Bug 2089979 Opened 13 days ago Closed 1 day ago

Give DecoderDoctorDiagnostics::mEvent a default initializer

Categories

(Core :: Audio/Video, task)

task

Tracking

()

RESOLVED FIXED
162 Branch
Tracking Status
firefox162 --- fixed

People

(Reporter: Sylvestre, Assigned: andrewt.tu, Mentored)

References

(Blocks 1 open bug)

Details

(Keywords: good-first-bug, Whiteboard: [lang=c++])

Attachments

(1 external file)

Filing as a good first bug to learn workflows.

Every other member of DecoderDoctorDiagnostics has a default initializer except DecoderDoctorEvent mEvent;, which makes Coverity report each DecoderDoctorDiagnostics diagnostics; local as uninitialized (four reports). Value-initialize it: DecoderDoctorEvent mEvent{};.

Current code:


  DecoderDoctorEvent mEvent;

Link to the code:
https://searchfox.org/firefox-main/source/dom/media/doctor/DecoderDoctorDiagnostics.h

To verify the fix:

./mach build

This was reported by Coverity Scan (CIDs 1694858, 1694948, 1695114, 1695120). The analyzer will stop reporting it once the change lands.

Tutorial to contribute:
https://firefox-source-docs.mozilla.org/contributing/contribution_quickref.html
https://firefox-source-docs.mozilla.org/contributing/stack_quickref.html

Please don't ask for the bug to be assigned. It will be automatically assigned to the first patch.

Assignee: nobody → andrewt.tu
Status: NEW → ASSIGNED
Pushed by alwu@mozilla.com: https://github.com/mozilla-firefox/firefox/commit/be29768a0fd7 https://hg.mozilla.org/integration/autoland/rev/b1a62859c570 Give DecoderDoctorDiagnostics::mEvent a default initializer. r=media-playback-reviewers,alwu
Status: ASSIGNED → RESOLVED
Closed: 1 day ago
Resolution: --- → FIXED
Target Milestone: --- → 162 Branch
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: