Mesa (master): r300g: fix macro substitution problem

Dave Airlie airlied at kemper.freedesktop.org
Mon Jul 26 02:06:49 UTC 2010


Module: Mesa
Branch: master
Commit: 8c26dc2bfeaa2504d6bcc31caa200299d47772b8
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=8c26dc2bfeaa2504d6bcc31caa200299d47772b8

Author: Dave Airlie <airlied at redhat.com>
Date:   Mon Jul 26 11:56:12 2010 +1000

r300g: fix macro substitution problem

isn't a problem yet, but have issues in hiz branch.

Signed-off-by: Dave Airlie <airlied at redhat.com>

---

 src/gallium/drivers/r300/r300_cs.h |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/gallium/drivers/r300/r300_cs.h b/src/gallium/drivers/r300/r300_cs.h
index 3beb625..c194d6a 100644
--- a/src/gallium/drivers/r300/r300_cs.h
+++ b/src/gallium/drivers/r300/r300_cs.h
@@ -136,8 +136,8 @@
 
 #define WRITE_CS_TABLE(values, count) do { \
     CS_DEBUG(assert(cs_count == 0);) \
-    memcpy(cs_copy->ptr + cs_copy->cdw, values, count * 4); \
-    cs_copy->cdw += count; \
+    memcpy(cs_copy->ptr + cs_copy->cdw, (values), (count) * 4); \
+    cs_copy->cdw += (count); \
 } while (0)
 
 #endif /* R300_CS_H */




More information about the mesa-commit mailing list