Closed Bug 559343 Opened 10 years ago Closed 9 years ago

cleanup oc_sb_create_plane_mapping

Categories

(Core :: Audio/Video, defect, major)

defect
Not set
major

Tracking

()

RESOLVED FIXED

People

(Reporter: timeless, Assigned: kinetik)

References

(Blocks 1 open bug, )

Details

(Keywords: coverity, Whiteboard: [sg:nse] correct address passed to memcpy with incorrect type)

Attachments

(1 file, 1 obsolete file)

55 static void oc_sb_create_plane_mapping(oc_sb_map _sb_maps[],
95       memset(_sb_maps[sbi][0],0xFF,sizeof(_sb_maps[sbi]));

Event overrun-buffer-arg: Overrun of static array "&_sb_maps[sbi][0]" of size 16 bytes by passing it to a function which indexes it with argument "64U" at byte position 63
The code in question appears valid. I've attached a patch which _should_ be equivalent and should avoid the report, however I have no way to test it to ensure coverity stops reporting a problem.
Group: core-security
Whiteboard: [sg:nse] correct address passed to memcpy with incorrect type
Comment on attachment 439131 [details] [diff] [review]
Patch to avoid error report.

this is indeed what i expected and what i think coverity expected.

let's push this and if coverity complains i'll apologize in a few months.
Attachment #439131 - Flags: review+
Attached patch patch v0Splinter Review
This is Tim's patch reformatted to make it easier to track against upstream.  If this silences the Coverity warning we can make sure it goes upstream.
Attachment #439131 - Attachment is obsolete: true
Attachment #442259 - Flags: review?(chris.double)
Attachment #442259 - Flags: review?(chris.double) → review+
Keywords: checkin-needed
Whiteboard: [sg:nse] correct address passed to memcpy with incorrect type → [needs landing] [sg:nse] correct address passed to memcpy with incorrect type
Status: UNCONFIRMED → ASSIGNED
Ever confirmed: true
http://hg.mozilla.org/mozilla-central/rev/756f81db342b
Status: ASSIGNED → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
Keywords: checkin-needed
Whiteboard: [needs landing] [sg:nse] correct address passed to memcpy with incorrect type → [sg:nse] correct address passed to memcpy with incorrect type
timeless, can you confirm that this shut Coverity up?
sorry for the delay. This indeed fixed the problem. Gecko upstream was pulled into our world in the middle of May and a Coverity run at the end of May reported this problem no longer existed.

Thanks. Sorry for not getting back to you sooner.
Status: RESOLVED → VERIFIED
Committed upstream in r17505.
Status: VERIFIED → RESOLVED
Closed: 10 years ago9 years ago
You need to log in before you can comment on or make changes to this bug.