summaryrefslogtreecommitdiff
path: root/src/Object.c
diff options
context:
space:
mode:
authorAlex Richardson <Alexander.Richardson@cl.cam.ac.uk>2021-06-16 14:33:31 +0100
committerAlan Coopersmith <alan.coopersmith@oracle.com>2021-06-27 18:35:02 +0000
commitdd3e028d2a1bc5daf87865ca1e5e923000186af8 (patch)
tree3d61848d2e92de694ca50addb1b6e1d6c3f0d1df /src/Object.c
parent38e89c8582efc8cd1e49205b5d02a10511738120 (diff)
downloadxorg-lib-libXt-dd3e028d2a1bc5daf87865ca1e5e923000186af8.tar.gz
Cast via intptr_t when converting integers to pointers
I found these by compiling libXt with the CHERI Clang compiler, as it warns about conversions from integer to pointer that do not use intptr_t. Signed-off-by: Alex Richardson <Alexander.Richardson@cl.cam.ac.uk>
Diffstat (limited to 'src/Object.c')
-rw-r--r--src/Object.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/Object.c b/src/Object.c
index 843ff7d..178bcb5 100644
--- a/src/Object.c
+++ b/src/Object.c
@@ -180,7 +180,7 @@ ConstructCallbackOffsets(WidgetClass myWidgetClass)
__XtMalloc((Cardinal)
(sizeof(XrmResource *) * (size_t) (tableSize + 1)));
- newTable[0] = (XrmResource *) (long) tableSize;
+ newTable[0] = (XrmResource *) (XtIntPtr) tableSize;
if (superTable)
tableSize -= (int) (long) superTable[0];