diff options
author | Alan Coopersmith <alan.coopersmith@oracle.com> | 2022-08-28 11:41:27 -0700 |
---|---|---|
committer | Alan Coopersmith <alan.coopersmith@oracle.com> | 2022-09-07 17:59:53 +0000 |
commit | 229c65d2dd6de511a005127245dc28d426ad6860 (patch) | |
tree | f88bf8b46f5679ed92e12318347640ecd61dfb03 /src/AddTrap.c | |
parent | cc4ad7a3990826ca44470dbca3a5b03c35548cab (diff) |
Reduce variable scopes as recommended by cppcheck
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Diffstat (limited to 'src/AddTrap.c')
-rw-r--r-- | src/AddTrap.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/AddTrap.c b/src/AddTrap.c index 421463d..7e2021e 100644 --- a/src/AddTrap.c +++ b/src/AddTrap.c @@ -36,15 +36,16 @@ XRenderAddTraps (Display *dpy, int ntrap) { XRenderExtDisplayInfo *info = XRenderFindDisplay (dpy); - xRenderAddTrapsReq *req; - int n; - long len; unsigned long max_req = dpy->bigreq_size ? dpy->bigreq_size : dpy->max_request_size; RenderSimpleCheckExtension (dpy, info); LockDisplay(dpy); while (ntrap) { + xRenderAddTrapsReq *req; + int n; + long len; + GetReq(RenderAddTraps, req); req->reqType = info->codes->major_opcode; req->renderReqType = X_RenderAddTraps; |