summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/mesa/drivers/dri/i965/gen6_constant_state.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/mesa/drivers/dri/i965/gen6_constant_state.c b/src/mesa/drivers/dri/i965/gen6_constant_state.c
index 62ad6b04976..121ba672575 100644
--- a/src/mesa/drivers/dri/i965/gen6_constant_state.c
+++ b/src/mesa/drivers/dri/i965/gen6_constant_state.c
@@ -32,7 +32,8 @@
static uint32_t
f_as_u32(float f)
{
- return *(uint32_t *)&f;
+ union fi fi = { .f = f };
+ return fi.ui;
}
static uint32_t