When you receive this event, the structure members are set as follows.

The serial member is the number of requests, starting from one, sent over
the network connection since it was opened. It is the number that was the
value of NextRequest immediately before the failing call was made.
The request_code member is a protocol request of the procedure that failed,
as defined in <X11/Xproto.h>.