summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlan Coopersmith <alan.coopersmith@oracle.com>2013-12-28 11:11:00 -0800
committerAlan Coopersmith <alan.coopersmith@oracle.com>2014-01-15 15:16:21 -0800
commite5e2ed5b115107d1b1d5248ac5c5dda67e71ea50 (patch)
tree2ddef2b1cb7b105ca6a25ba9a5ee7eca07842c98
parent148d89f0b3a652acc54b1a21807ffd6d0e81e279 (diff)
downloadxorg-proto-x11proto-e5e2ed5b115107d1b1d5248ac5c5dda67e71ea50.tar.gz
Add more comments on connection setup to Xproto.h
Some of the bits I forget and have to dig out of the protocol spec every few years when I need to know again. Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
-rw-r--r--Xproto.h17
1 files changed, 15 insertions, 2 deletions
diff --git a/Xproto.h b/Xproto.h
index 76e2c99..6cdea89 100644
--- a/Xproto.h
+++ b/Xproto.h
@@ -259,10 +259,13 @@ restoring the definitions in X.h. */
typedef CARD16 KeyButMask;
/*****************
- connection setup structure. This is followed by
- numRoots xWindowRoot structs.
+ Connection setup structures. See Chapter 8: Connection Setup
+ of the X Window System Protocol specification for details.
*****************/
+/* Client initiates handshake with this data, followed by the strings
+ * for the auth protocol & data.
+ */
typedef struct {
CARD8 byteOrder;
BYTE pad;
@@ -272,6 +275,16 @@ typedef struct {
CARD16 pad2 B16;
} xConnClientPrefix;
+/* Server response to xConnClientPrefix.
+ *
+ * If success == Success, this is followed by xConnSetup and
+ * numRoots xWindowRoot structs.
+ *
+ * If success == Failure, this is followed by a reason string.
+ *
+ * The protocol also defines a case of success == Authenticate, but
+ * that doesn't seem to have ever been implemented by the X Consortium.
+ */
typedef struct {
CARD8 success;
BYTE lengthReason; /*num bytes in string following if failure */