Index: lib/X11/GetWAttrs.c =================================================================== RCS file: /home/eich/cvs/xc/lib/X11/GetWAttrs.c,v retrieving revision 1.1.1.4 diff -u -r1.1.1.4 GetWAttrs.c --- lib/X11/GetWAttrs.c 22 Apr 2003 18:03:09 -0000 1.1.1.4 +++ lib/X11/GetWAttrs.c 26 Aug 2004 14:38:35 -0000 @@ -24,7 +24,6 @@ in this Software without prior written authorization from The Open Group. */ -/* $XFree86$ */ #define NEED_REPLIES #include "Xlibint.h" @@ -84,10 +83,11 @@ return True; } -Status XGetWindowAttributes(dpy, w, attr) - register Display *dpy; - Window w; - XWindowAttributes *attr; +Status +_XGetWindowAttributes( + register Display *dpy, + Window w, + XWindowAttributes *attr) { xGetGeometryReply rep; register xResourceReq *req; @@ -96,7 +96,6 @@ _XAsyncHandler async; _XWAttrsState async_state; - LockDisplay(dpy); GetResReq(GetWindowAttributes, w, req); async_state.attr_seq = dpy->request; @@ -113,14 +112,10 @@ if (!_XReply (dpy, (xReply *)&rep, 0, xTrue)) { DeqAsyncHandler(dpy, &async); - UnlockDisplay(dpy); - SyncHandle(); return (0); } DeqAsyncHandler(dpy, &async); if (!async_state.attr) { - UnlockDisplay(dpy); - SyncHandle(); return (0); } attr->x = cvtINT16toInt (rep.x); @@ -138,8 +133,22 @@ break; } } + return(1); +} + +Status +XGetWindowAttributes( + Display *dpy, + Window w, + XWindowAttributes *attr) +{ + Status ret; + + LockDisplay(dpy); + ret = _XGetWindowAttributes(dpy, w, attr); UnlockDisplay(dpy); SyncHandle(); - return(1); + + return ret; } Index: lib/X11/PutBEvent.c =================================================================== RCS file: /home/eich/cvs/xc/lib/X11/PutBEvent.c,v retrieving revision 1.1.1.3 diff -u -r1.1.1.3 PutBEvent.c --- lib/X11/PutBEvent.c 20 Dec 2001 12:37:27 -0000 1.1.1.3 +++ lib/X11/PutBEvent.c 26 Aug 2004 14:38:35 -0000 @@ -33,16 +33,14 @@ #include "Xlibint.h" int -XPutBackEvent (dpy, event) - register Display *dpy; - register XEvent *event; +_XPutBackEvent ( + register Display *dpy, + register XEvent *event) { register _XQEvent *qelt; - LockDisplay(dpy); if (!dpy->qfree) { if ((dpy->qfree = (_XQEvent *) Xmalloc (sizeof (_XQEvent))) == NULL) { - UnlockDisplay(dpy); return 0; } dpy->qfree->next = NULL; @@ -56,6 +54,18 @@ if (dpy->tail == NULL) dpy->tail = qelt; dpy->qlen++; - UnlockDisplay(dpy); return 0; + } + +int +XPutBackEvent ( + register Display * dpy, + register XEvent *event) + { + int ret; + + LockDisplay(dpy); + ret = _XPutBackEvent(dpy, event); + UnlockDisplay(dpy); + return ret; } Index: lib/X11/Xlibint.h =================================================================== RCS file: /home/eich/cvs/xc/lib/X11/Xlibint.h,v retrieving revision 1.1.1.13 diff -u -r1.1.1.13 Xlibint.h --- lib/X11/Xlibint.h 6 Jul 2004 15:06:37 -0000 1.1.1.13 +++ lib/X11/Xlibint.h 26 Aug 2004 14:38:35 -0000 @@ -1298,6 +1298,15 @@ int n, int ordering); +Status _XGetWindowAttributes( + register Display *dpy, + Window w, + XWindowAttributes *attr); + +int _XPutBackEvent ( + register Display *dpy, + register XEvent *event); + _XFUNCPROTOEND #endif /* _XLIBINT_H_ */ Index: lib/X11/imDefLkup.c =================================================================== RCS file: /home/eich/cvs/xc/lib/X11/imDefLkup.c,v retrieving revision 1.1.1.8 diff -u -r1.1.1.8 imDefLkup.c --- lib/X11/imDefLkup.c 2 Dec 2003 18:40:30 -0000 1.1.1.8 +++ lib/X11/imDefLkup.c 26 Aug 2004 14:38:35 -0000 @@ -463,7 +463,7 @@ Xim im = (Xim )ic->core.im; XWindowAttributes atr; - if (!XGetWindowAttributes(im->core.display, ic->core.focus_window, &atr)) + if (!_XGetWindowAttributes(im->core.display, ic->core.focus_window, &atr)) return 0; return (EVENTMASK)atr.your_event_mask; } Index: lib/X11/imLcFlt.c =================================================================== RCS file: /home/eich/cvs/xc/lib/X11/imLcFlt.c,v retrieving revision 1.1.1.2 diff -u -r1.1.1.2 imLcFlt.c --- lib/X11/imLcFlt.c 29 Jan 2001 14:21:10 -0000 1.1.1.2 +++ lib/X11/imLcFlt.c 26 Aug 2004 14:38:35 -0000 @@ -73,7 +73,7 @@ ic->private.local.composed = p; /* return back to client KeyPressEvent keycode == 0 */ ev->xkey.keycode = 0; - XPutBackEvent(d, ev); + _XPutBackEvent(d, ev); /* initialize internal state for next key sequence */ ic->private.local.context = ((Xim)ic->core.im)->private.local.top; return(True);