xserver: Branch 'master'

Keith Packard keithp at kemper.freedesktop.org
Tue Jul 3 14:43:44 PDT 2007


 composite/compext.c |   13 ++++++++-----
 1 files changed, 8 insertions(+), 5 deletions(-)

New commits:
diff-tree 4f88d68bdb90cc7d12170355105b4fd020acd306 (from 866f092ca0160a366add01b48ad03438926c4d16)
Author: Keith Packard <keithp at neko.keithp.com>
Date:   Tue Jul 3 14:43:17 2007 -0700

    Force advertised Composite version to 0.4 instead of using header version.
    
    Installed protocol header version may be newer than the server code base.
    Use internal version number for Composite extension to make sure the server
    doesn't advertise capabilities it doesn't support.

diff --git a/composite/compext.c b/composite/compext.c
index 3a43be3..9cf6bfe 100644
--- a/composite/compext.c
+++ b/composite/compext.c
@@ -46,6 +46,9 @@
 
 #include "compint.h"
 
+#define SERVER_COMPOSITE_MAJOR	0
+#define SERVER_COMPOSITE_MINOR	4
+
 static CARD8	CompositeReqCode;
 static int	CompositeClientPrivateIndex;
 RESTYPE		CompositeClientWindowType;
@@ -130,16 +133,16 @@ ProcCompositeQueryVersion (ClientPtr cli
     rep.type = X_Reply;
     rep.length = 0;
     rep.sequenceNumber = client->sequence;
-    if (stuff->majorVersion < COMPOSITE_MAJOR) {
+    if (stuff->majorVersion < SERVER_COMPOSITE_MAJOR) {
 	rep.majorVersion = stuff->majorVersion;
 	rep.minorVersion = stuff->minorVersion;
     } else {
-	rep.majorVersion = COMPOSITE_MAJOR;
-	if (stuff->majorVersion == COMPOSITE_MAJOR && 
-	    stuff->minorVersion < COMPOSITE_MINOR)
+	rep.majorVersion = SERVER_COMPOSITE_MAJOR;
+	if (stuff->majorVersion == SERVER_COMPOSITE_MAJOR && 
+	    stuff->minorVersion < SERVER_COMPOSITE_MINOR)
 	    rep.minorVersion = stuff->minorVersion;
 	else
-	    rep.minorVersion = COMPOSITE_MINOR;
+	    rep.minorVersion = SERVER_COMPOSITE_MINOR;
     }
     pCompositeClient->major_version = rep.majorVersion;
     pCompositeClient->minor_version = rep.minorVersion;


More information about the xorg-commit mailing list