summaryrefslogtreecommitdiff
path: root/src/gallium/auxiliary/pipebuffer/pb_bufmgr_fenced.c
diff options
context:
space:
mode:
authorJosé Fonseca <jrfonseca@tungstengraphics.com>2008-10-28 16:11:09 +0900
committerJosé Fonseca <jrfonseca@tungstengraphics.com>2008-11-03 22:35:18 +0900
commit28a2edb7389107cd46eb382a44d339dd7972310a (patch)
tree7cb8b1d6ed1b5d9b6ece8958ee63cceea20fe3cd /src/gallium/auxiliary/pipebuffer/pb_bufmgr_fenced.c
parent467c4760b337a541c7af27f1ed3bd5c4ecba316f (diff)
pipebuffer: Ensure refcounts of live buffer objects are never zero.
Diffstat (limited to 'src/gallium/auxiliary/pipebuffer/pb_bufmgr_fenced.c')
-rw-r--r--src/gallium/auxiliary/pipebuffer/pb_bufmgr_fenced.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/gallium/auxiliary/pipebuffer/pb_bufmgr_fenced.c b/src/gallium/auxiliary/pipebuffer/pb_bufmgr_fenced.c
index 633ee70a75..e2594ea236 100644
--- a/src/gallium/auxiliary/pipebuffer/pb_bufmgr_fenced.c
+++ b/src/gallium/auxiliary/pipebuffer/pb_bufmgr_fenced.c
@@ -86,8 +86,7 @@ fenced_bufmgr_create_buffer(struct pb_manager *mgr,
fenced_buf = fenced_buffer_create(fenced_mgr->fenced_list, buf);
if(!fenced_buf) {
- assert(buf->base.refcount == 1);
- pb_destroy(buf);
+ pb_reference(&buf, NULL);
}
return fenced_buf;