summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlan Coopersmith <alan.coopersmith@oracle.com>2022-08-20 11:07:02 -0700
committerAlan Coopersmith <alan.coopersmith@oracle.com>2022-08-20 11:07:02 -0700
commit8cb2b07b8f83bc6385c41c7cdd6051a66dced0ff (patch)
tree6bd29e19844269b02be86043bc6cc8b69ee6e6dd
parentca196d7545020037ed5533ff1cb3ebb52823af8e (diff)
Update GetOldReq to use _XGetRequest()
Requires libX11 1.5 or later, but configure.ac already requires x11 >= 1.6 Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
-rw-r--r--src/XF86VMode.c10
1 files changed, 2 insertions, 8 deletions
diff --git a/src/XF86VMode.c b/src/XF86VMode.c
index 48fb6c1..577df00 100644
--- a/src/XF86VMode.c
+++ b/src/XF86VMode.c
@@ -418,14 +418,8 @@ XF86VidModeGetAllModeLines(Display* dpy, int screen, int* modecount,
* GetReq replacement for use with VidMode protocols earlier than 2.0
*/
#define GetOldReq(name, oldname, req) \
- WORD64ALIGN\
- if ((dpy->bufptr + SIZEOF(x##oldname##Req)) > dpy->bufmax)\
- _XFlush(dpy);\
- req = (x##oldname##Req *)(dpy->last_req = dpy->bufptr);\
- req->reqType = X_##name;\
- req->length = (SIZEOF(x##oldname##Req))>>2;\
- dpy->bufptr += SIZEOF(x##oldname##Req);\
- dpy->request++
+ req = (x##oldname##Req *) \
+ _XGetRequest(dpy, X_##name, SIZEOF(x##oldname##Req))
Bool
XF86VidModeAddModeLine(Display *dpy, int screen,