i915: Fixed initialization of surface
authorJakob Bornecrantz <jakob@tungstengraphics.com>
Fri, 30 May 2008 16:46:40 +0000 (18:46 +0200)
committerJakob Bornecrantz <jakob@aurora.(none)>
Mon, 2 Jun 2008 10:59:59 +0000 (12:59 +0200)
src/gallium/drivers/i915simple/i915_texture.c

index f0d00280c23595e1b7e8ec975074e0febc98b4a6..16354dce50909375d3c202ec6fce847adc8f8a3b 100644 (file)
@@ -624,8 +624,8 @@ i915_get_tex_surface(struct pipe_screen *screen,
 
    ps = CALLOC_STRUCT(pipe_surface);//ws->surface_alloc(ws);
    if (ps) {
-      assert(ps->refcount);
-      assert(ps->winsys);
+      ps->refcount = 1;
+      ps->winsys = ws;
       pipe_texture_reference(&ps->texture, pt);
       pipe_buffer_reference(ws, &ps->buffer, tex->buffer);
       ps->format = pt->format;