From: José Fonseca Date: Fri, 12 Oct 2012 16:02:55 +0000 (+0100) Subject: mesa/st: Fix assertions. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=23c6b8f2edc42a483148c3d7357331bccf1edd11;p=mesa.git mesa/st: Fix assertions. Can't access ptDraw before it is written. --- diff --git a/src/mesa/state_tracker/st_cb_drawpixels.c b/src/mesa/state_tracker/st_cb_drawpixels.c index 121496a41cd..4e2edd2e7fd 100644 --- a/src/mesa/state_tracker/st_cb_drawpixels.c +++ b/src/mesa/state_tracker/st_cb_drawpixels.c @@ -1241,8 +1241,8 @@ copy_stencil_pixels(struct gl_context *ctx, GLint srcx, GLint srcy, dsty = rbDraw->Base.Height - dsty - height; } - assert(util_format_get_blockwidth(ptDraw->resource->format) == 1); - assert(util_format_get_blockheight(ptDraw->resource->format) == 1); + assert(util_format_get_blockwidth(rbDraw->texture->format) == 1); + assert(util_format_get_blockheight(rbDraw->texture->format) == 1); /* map the stencil buffer */ drawMap = pipe_transfer_map(pipe,