Skip to content

Commit

Permalink
Compext.c: fix misleading error message
Browse files Browse the repository at this point in the history
An X reply contains a type which is X_Reply or X_Error. This is not an
opcode which is when installing the handler.
  • Loading branch information
uli42 committed Mar 10, 2021
1 parent 2770b8e commit e3e765f
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions nx-X11/programs/Xserver/hw/nxagent/compext/Compext.c
Original file line number Diff line number Diff line change
Expand Up @@ -3461,7 +3461,7 @@ static Bool _NXCollectImageHandler(Display *dpy, xReply *rep, char *buf,
((int)(state -> sequence) % 65536))
{
#ifdef TEST_IMAGE
fprintf(stderr, "******_NXCollectImageHandler: Unmatched sequence [%d] for opcode [%d] "
fprintf(stderr, "******_NXCollectImageHandler: Unmatched sequence [%d] of type [%d] "
"with length [%d].\n", rep -> generic.sequenceNumber, rep -> generic.type,
(int) rep -> generic.length << 2);
#endif
Expand Down Expand Up @@ -3856,9 +3856,10 @@ static Bool _NXCollectPropertyHandler(Display *dpy, xReply *rep, char *buf,
((int)(state -> sequence) % 65536))
{
#ifdef TEST_PROPERTY
fprintf(stderr, "******_NXCollectPropertyHandler: Unmatched sequence [%d] for opcode [%d] "
"with length [%d].\n", rep -> generic.sequenceNumber, rep -> generic.type,
fprintf(stderr, "******_NXCollectPropertyHandler: Unmatched sequence [%d] of type [%d] "
"with length [%d].\n", rep -> generic.sequenceNumber, rep -> generic.type,
(int) rep -> generic.length << 2);

#endif

return False;
Expand Down Expand Up @@ -4228,7 +4229,7 @@ static Bool _NXCollectGrabPointerHandler(Display *dpy, xReply *rep, char *buf,
((int)(state -> sequence) % 65536))
{
#ifdef TEST_POINTER
fprintf(stderr, "******_NXCollectGrabPointerHandler: Unmatched sequence [%d] for opcode [%d] "
fprintf(stderr, "******_NXCollectGrabPointerHandler: Unmatched sequence [%d] of type [%d] "
"with length [%d].\n", rep -> generic.sequenceNumber, rep -> generic.type,
(int) rep -> generic.length << 2);
#endif
Expand Down Expand Up @@ -4520,7 +4521,7 @@ static Bool _NXCollectInputFocusHandler(Display *dpy, xReply *rep, char *buf,
((int)(state -> sequence) % 65536))
{
#ifdef TEST_INPUT
fprintf(stderr, "******_NXCollectInputFocusHandler: Unmatched sequence [%d] for opcode [%d] "
fprintf(stderr, "******_NXCollectInputFocusHandler: Unmatched sequence [%d] of type [%d] "
"with length [%d].\n", rep -> generic.sequenceNumber, rep -> generic.type,
(int) rep -> generic.length << 2);
#endif
Expand Down

0 comments on commit e3e765f

Please sign in to comment.