present: Don't use the major/minor version from the protocol headers

We want to advertise the version we implement, not the version the
protocol headers happen to describe.

Reviewed-by: Jasper St. Pierre <<jstpierre@mecheye.net>
Signed-off-by: Adam Jackson <ajax@redhat.com>
This commit is contained in:
Adam Jackson 2013-12-13 11:39:16 -05:00
parent ec6087bf07
commit 128449dd64
2 changed files with 7 additions and 2 deletions

View File

@ -67,6 +67,10 @@
#define SERVER_PANORAMIX_MAJOR_VERSION 1 #define SERVER_PANORAMIX_MAJOR_VERSION 1
#define SERVER_PANORAMIX_MINOR_VERSION 1 #define SERVER_PANORAMIX_MINOR_VERSION 1
/* Present */
#define SERVER_PRESENT_MAJOR_VERSION 1
#define SERVER_PRESENT_MINOR_VERSION 0
/* RandR */ /* RandR */
#define SERVER_RANDR_MAJOR_VERSION 1 #define SERVER_RANDR_MAJOR_VERSION 1
#define SERVER_RANDR_MINOR_VERSION 4 #define SERVER_RANDR_MINOR_VERSION 4

View File

@ -26,6 +26,7 @@
#include "present_priv.h" #include "present_priv.h"
#include "randrstr.h" #include "randrstr.h"
#include <protocol-versions.h>
static int static int
proc_present_query_version(ClientPtr client) proc_present_query_version(ClientPtr client)
@ -35,8 +36,8 @@ proc_present_query_version(ClientPtr client)
.type = X_Reply, .type = X_Reply,
.sequenceNumber = client->sequence, .sequenceNumber = client->sequence,
.length = 0, .length = 0,
.majorVersion = PRESENT_MAJOR, .majorVersion = SERVER_PRESENT_MAJOR_VERSION,
.minorVersion = PRESENT_MINOR .minorVersion = SERVER_PRESENT_MINOR_VERSION
}; };
REQUEST_SIZE_MATCH(xPresentQueryVersionReq); REQUEST_SIZE_MATCH(xPresentQueryVersionReq);