r300g: fix fence referencing
authorMarek Olšák <maraeo@gmail.com>
Wed, 26 May 2010 14:39:14 +0000 (16:39 +0200)
committerMarek Olšák <maraeo@gmail.com>
Wed, 26 May 2010 14:39:32 +0000 (16:39 +0200)
src/gallium/drivers/r300/r300_flush.c

index 9cda940c85d69b90b05e1d7ba3e2b7e2fb62cbc0..360b19a0c1ed74ec4871f5188ef27a1f51ebb68d 100644 (file)
@@ -77,6 +77,7 @@ static void r300_flush(struct pipe_context* pipe,
     /* Create a new fence. */
     if (rfence) {
         *rfence = CALLOC_STRUCT(r300_fence);
+        pipe_reference_init(&(*rfence)->reference, 1);
         (*rfence)->ctx = r300;
     }
 }