[Mesa-dev] [Bug 94711] Patch for pb_reference to explicitly handle NULL src
bugzilla-daemon at freedesktop.org
bugzilla-daemon at freedesktop.org
Sat Mar 26 02:55:31 UTC 2016
https://bugs.freedesktop.org/show_bug.cgi?id=94711
Bug ID: 94711
Summary: Patch for pb_reference to explicitly handle NULL src
Product: Mesa
Version: 11.1
Hardware: Other
OS: All
Status: NEW
Severity: normal
Priority: medium
Component: Other
Assignee: mesa-dev at lists.freedesktop.org
Reporter: john at feith.com
QA Contact: mesa-dev at lists.freedesktop.org
Created attachment 122572
--> https://bugs.freedesktop.org/attachment.cgi?id=122572&action=edit
Patch for problem.
Noticed while looking at a crash that pb_reference is called in several
places with src set to NULL which is interesting since pb_reference then
calls pipe_reference with &src->reference. The existing code works since
struct pb_buffer looks like:
struct pb_buffer {
struct pipe_reference reference;
...
meaning &src->reference with src = NULL happens to equal NULL. The
attached patch explicitly handles src = NULL which is less fragile and
clearly communicates that being passed NULL is valid.
--
You are receiving this mail because:
You are the assignee for the bug.
You are the QA Contact for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/mesa-dev/attachments/20160326/9613a42d/attachment.html>
More information about the mesa-dev
mailing list