From: Alan Coopersmith Date: Wed, 25 Mar 2009 03:51:53 +0000 (-0700) Subject: r300_cmdbuf.c: convert cast to a form supported by Sun cc X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=ff421b6e0b3ef218799350358b9bff5610f17c3a;p=mesa.git r300_cmdbuf.c: convert cast to a form supported by Sun cc Fixes Sun cc error: "r300_cmdbuf.c", line 142: invalid cast expression Signed-off-by: Alan Coopersmith --- diff --git a/src/mesa/drivers/dri/r300/r300_cmdbuf.c b/src/mesa/drivers/dri/r300/r300_cmdbuf.c index 3eb2dc8f5a0..f4472756f10 100644 --- a/src/mesa/drivers/dri/r300/r300_cmdbuf.c +++ b/src/mesa/drivers/dri/r300/r300_cmdbuf.c @@ -139,7 +139,7 @@ static void r300PrintStateAtom(r300ContextPtr r300, struct r300_state_atom *stat if (RADEON_DEBUG & DEBUG_VERBOSE) { for (i = 0; i < dwords;) { - cmd = (drm_r300_cmd_header_t) state->cmd[i]; + cmd = *((drm_r300_cmd_header_t *) &state->cmd[i]); reg = (cmd.packet0.reghi << 8) | cmd.packet0.reglo; fprintf(stderr, " %s[%d]: cmdpacket0 (first reg=0x%04x, count=%d)\n", state->name, i, reg, cmd.packet0.count);