aboutsummaryrefslogtreecommitdiff
path: root/libXaw
diff options
context:
space:
mode:
Diffstat (limited to 'libXaw')
-rw-r--r--libXaw/src/Pixmap.c6
-rw-r--r--libXaw/src/XawIm.c4
2 files changed, 5 insertions, 5 deletions
diff --git a/libXaw/src/Pixmap.c b/libXaw/src/Pixmap.c
index 1c5a8c5ed..0741b052f 100644
--- a/libXaw/src/Pixmap.c
+++ b/libXaw/src/Pixmap.c
@@ -47,7 +47,7 @@
* Types
*/
typedef struct _XawCache {
- long value;
+ intptr_t value;
XtPointer *elems;
unsigned int num_elems;
} XawCache;
@@ -415,7 +415,7 @@ qcmp_string(register _Xconst void *left, register _Xconst void *right)
static int
bcmp_long(register _Xconst void *value, register _Xconst void *cache)
{
- return ((long)value - (long)((*(XawCache **)cache)->value));
+ return ((intptr_t)value - (intptr_t)((*(XawCache **)cache)->value));
}
static int
@@ -492,7 +492,7 @@ _XawGetCache(XawCache *xaw, Screen *screen, Colormap colormap, int depth)
XtRealloc((char *)xaw->elems,
sizeof(XtPointer) * xaw->num_elems);
}
- pcache->value = (long)screen;
+ pcache->value = (intptr_t)screen;
pcache->elems = NULL;
pcache->num_elems = 0;
xaw->elems[xaw->num_elems - 1] = (XtPointer)pcache;
diff --git a/libXaw/src/XawIm.c b/libXaw/src/XawIm.c
index 7a7152fb6..ee0a09a6e 100644
--- a/libXaw/src/XawIm.c
+++ b/libXaw/src/XawIm.c
@@ -196,7 +196,7 @@ SetExtPart(VendorShellWidget w, XawVendorShellExtWidget vew)
contextData = XtNew(contextDataRec);
contextData->parent = (Widget)w;
contextData->ve = (Widget)vew;
- if (XSaveContext(XtDisplay(w), (Window)w, extContext, (char *)contextData)) {
+ if (XSaveContext(XtDisplay(w), (Window)(((intptr_t)w)&0xffffffff), extContext, (char *)contextData)) {
return(NULL);
}
return(&(vew->vendor_ext));
@@ -208,7 +208,7 @@ GetExtPart(VendorShellWidget w)
contextDataRec *contextData;
XawVendorShellExtWidget vew;
- if (XFindContext(XtDisplay(w), (Window)w, extContext,
+ if (XFindContext(XtDisplay(w), (Window)(((intptr_t)w)& 0xffffffff), extContext,
(XPointer*)&contextData)) {
return(NULL);
}