[PATCH xserver] exa: promise not to touch the data when swapping pointers
Eric Engestrom
eric.engestrom at imgtec.com
Tue Mar 13 10:55:22 UTC 2018
exa/exa.c:525:10: warning: initialization discards ‘const’ qualifier from pointer target type [-Wdiscarded-qualifiers]
swap(pExaGC, pGC, funcs);
^
Signed-off-by: Eric Engestrom <eric.engestrom at imgtec.com>
---
exa/exa_priv.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/exa/exa_priv.h b/exa/exa_priv.h
index ca4db720fbe871b50b7e..912e214789adba95c7fa 100644
--- a/exa/exa_priv.h
+++ b/exa/exa_priv.h
@@ -244,7 +244,7 @@ extern DevPrivateKeyRec exaScreenPrivateKeyRec;
}
#else
#define swap(priv, real, mem) {\
- void *tmp = priv->Saved##mem; \
+ const void *tmp = priv->Saved##mem; \
priv->Saved##mem = real->mem; \
real->mem = tmp; \
}
--
Cheers,
Eric
More information about the xorg-devel
mailing list