only assert front/back pitch if double-buffered (bug 7663)
authorBrian Paul <brian.paul@tungstengraphics.com>
Thu, 29 Jun 2006 15:44:13 +0000 (15:44 +0000)
committerBrian Paul <brian.paul@tungstengraphics.com>
Thu, 29 Jun 2006 15:44:13 +0000 (15:44 +0000)
src/mesa/drivers/dri/unichrome/via_context.c

index 183f3d3479f3cef6f21f3ffc479e08b29e11c798..dabb233fc026932f169f6e5cc97d667c7172319c 100644 (file)
@@ -336,7 +336,9 @@ calculate_buffer_parameters( struct via_context *vmesa,
    if( vmesa->viaScreen->width == vmesa->driDrawable->w && 
        vmesa->viaScreen->height == vmesa->driDrawable->h ) {
       vmesa->doPageFlip = vmesa->allowPageFlip;
-      assert(vmesa->back.pitch == vmesa->front.pitch);
+      if (vmesa->hasBack) {
+         assert(vmesa->back.pitch == vmesa->front.pitch);
+      }
    }
    else
       vmesa->doPageFlip = GL_FALSE;