diff options
author | Eric Anholt <[email protected]> | 2007-05-18 12:59:39 -0700 |
---|---|---|
committer | Eric Anholt <[email protected]> | 2007-05-18 12:59:39 -0700 |
commit | 431baf221ea7858ecb5edb2a5a01b5f993147a4d (patch) | |
tree | 13f190f66891902e0bd318b9c182468fba91d023 | |
parent | 425d0c6305f7781788077452ae9e2de595b0961d (diff) |
Allow unreference with a NULL argument.
-rw-r--r-- | src/mesa/drivers/dri/common/dri_bufmgr.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/mesa/drivers/dri/common/dri_bufmgr.c b/src/mesa/drivers/dri/common/dri_bufmgr.c index f60d3b0db6b..dd76e8ead65 100644 --- 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); } |