From: Michel Dänzer Date: Fri, 21 Aug 2009 23:24:39 +0000 (+0200) Subject: Fix r300 VBO support build on big endian. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=6b1f144d9b75ffed88e7d1ae3e05943c34db7905;p=mesa.git Fix r300 VBO support build on big endian. --- diff --git a/src/mesa/drivers/dri/r300/r300_draw.c b/src/mesa/drivers/dri/r300/r300_draw.c index dbf5384d558..e98dc335183 100644 --- a/src/mesa/drivers/dri/r300/r300_draw.c +++ b/src/mesa/drivers/dri/r300/r300_draw.c @@ -108,11 +108,11 @@ static void r300FixupIndexBuffer(GLcontext *ctx, const struct _mesa_index_buffer #if MESA_BIG_ENDIAN } else { /* if (mesa_ind_buf->type == GL_UNSIGNED_SHORT) */ - GLuint size; GLushort *in = (GLushort *)src_ptr; - size = sizeof(GLushort) * ((mesa_ind_buf->count + 1) & ~1); + GLuint size = sizeof(GLushort) * ((mesa_ind_buf->count + 1) & ~1); - radeonAllocDmaRegion(&r300->radeon, &r300->ind_buf.bo, &r300->ind_buf.bo_offet, size, 4); + radeonAllocDmaRegion(&r300->radeon, &r300->ind_buf.bo, + &r300->ind_buf.bo_offset, size, 4); assert(r300->ind_buf.bo->ptr != NULL); out = (GLuint *)ADD_POINTERS(r300->ind_buf.bo->ptr, r300->ind_buf.bo_offset);