summaryrefslogtreecommitdiff
path: root/include/X11/Intrinsic.h
diff options
context:
space:
mode:
authorAlex Richardson <Alexander.Richardson@cl.cam.ac.uk>2021-06-16 14:32:44 +0100
committerAlan Coopersmith <alan.coopersmith@oracle.com>2021-06-27 18:35:02 +0000
commit38e89c8582efc8cd1e49205b5d02a10511738120 (patch)
tree3dee9b8f028b5eee3b85e9c7a9beadf71117b6d9 /include/X11/Intrinsic.h
parentcfa8e152141367edb7b53e90da4ad80e995f3607 (diff)
Use XtUIntPtr for integer types that can hold pointers
Various Xt*Id types are integer types that are used to hold pointers. Use uintptr_t for standards-compliant conversion and to support architectures where long cannot hold pointers (e.g. CHERI). 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 'include/X11/Intrinsic.h')
-rw-r--r--include/X11/Intrinsic.h10
1 files changed, 5 insertions, 5 deletions
diff --git a/include/X11/Intrinsic.h b/include/X11/Intrinsic.h
index 9bcc8dc..668b7d5 100644
--- a/include/X11/Intrinsic.h
+++ b/include/X11/Intrinsic.h
@@ -131,10 +131,10 @@ typedef struct _XtEventRec *XtEventTable;
typedef struct _XtAppStruct *XtAppContext;
typedef unsigned long XtValueMask;
-typedef unsigned long XtIntervalId;
-typedef unsigned long XtInputId;
-typedef unsigned long XtWorkProcId;
-typedef unsigned long XtSignalId;
+typedef XtUIntPtr XtIntervalId;
+typedef XtUIntPtr XtInputId;
+typedef XtUIntPtr XtWorkProcId;
+typedef XtUIntPtr XtSignalId;
typedef unsigned int XtGeometryMask;
typedef unsigned long XtGCMask; /* Mask of values that are used by widget*/
typedef unsigned long Pixel; /* Index into colormap */
@@ -283,7 +283,7 @@ typedef void (*XtActionHookProc)(
Cardinal* /* num_params */
);
-typedef unsigned long XtBlockHookId;
+typedef XtUIntPtr XtBlockHookId;
typedef void (*XtBlockHookProc)(
XtPointer /* client_data */