projects
/
profile
/
ivi
/
mesa.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
425d0c6
)
Allow unreference with a NULL argument.
author
Eric Anholt
<eric@anholt.net>
Fri, 18 May 2007 19:59:39 +0000
(12:59 -0700)
committer
Eric Anholt
<eric@anholt.net>
Fri, 18 May 2007 19:59:39 +0000
(12:59 -0700)
src/mesa/drivers/dri/common/dri_bufmgr.c
patch
|
blob
|
history
diff --git
a/src/mesa/drivers/dri/common/dri_bufmgr.c
b/src/mesa/drivers/dri/common/dri_bufmgr.c
index
f60d3b0
..
dd76e8e
100644
(file)
--- a/
src/mesa/drivers/dri/common/dri_bufmgr.c
+++ b/
src/mesa/drivers/dri/common/dri_bufmgr.c
@@
-58,6
+58,9
@@
dri_bo_reference(dri_bo *bo)
void
dri_bo_unreference(dri_bo *bo)
{
+ if (bo == NULL)
+ return;
+
bo->bufmgr->bo_unreference(bo);
}
@@
-100,6
+103,9
@@
dri_fence_reference(dri_fence *fence)
void
dri_fence_unreference(dri_fence *fence)
{
+ if (fence == NULL)
+ return;
+
fence->bufmgr->fence_unreference(fence);
}