projects
/
mesa.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
951fdac
)
ws/i965: allow NULL buffer in winsys::bo_unreference
author
Keith Whitwell
<keithw@vmware.com>
Wed, 4 Nov 2009 23:09:05 +0000
(23:09 +0000)
committer
Keith Whitwell
<keithw@vmware.com>
Wed, 4 Nov 2009 23:09:05 +0000
(23:09 +0000)
Special case to avoid clutter in the driver
src/gallium/winsys/drm/i965/xlib/xlib_i965.c
patch
|
blob
|
history
diff --git
a/src/gallium/winsys/drm/i965/xlib/xlib_i965.c
b/src/gallium/winsys/drm/i965/xlib/xlib_i965.c
index 4ce22a5a49ab402f770d4f02bf7705b3c662406e..08fce4b20b881f69221db0104fc760d324afd5f1 100644
(file)
--- a/
src/gallium/winsys/drm/i965/xlib/xlib_i965.c
+++ b/
src/gallium/winsys/drm/i965/xlib/xlib_i965.c
@@
-154,6
+154,12
@@
xlib_brw_bo_unreference( struct brw_winsys_buffer *buffer )
{
struct xlib_brw_buffer *buf = xlib_brw_buffer(buffer);
+ /* As a special favor in this call only, buffer is allowed to be
+ * NULL:
+ */
+ if (buffer == NULL)
+ return;
+
if (--buf->cheesy_refcount == 0) {
FREE(buffer);
}