summaryrefslogtreecommitdiff
path: root/exa/exa.c
diff options
context:
space:
mode:
authorTilman Sauerbeck <tilman@code-monkey.de>2007-09-22 13:02:08 +0200
committerTilman Sauerbeck <tilman@code-monkey.de>2007-09-22 13:52:56 +0200
commitedd88170836ec985ab1a59179de69d50644b8dff (patch)
tree7d27b35907e4c8b3f450ca02c022d2c36851cba4 /exa/exa.c
parentabe0a51f3f790f8c055289465e130177c4b647cc (diff)
EXA: Check ABI compatibility earlier.
If the driver isn't compatible to the server, all bets are off anyway wrt the contents of the fields that we're validating, which can lead to bogus error messages.
Diffstat (limited to 'exa/exa.c')
-rw-r--r--exa/exa.c22
1 files changed, 11 insertions, 11 deletions
diff --git a/exa/exa.c b/exa/exa.c
index eac2d91ce..620502730 100644
--- a/exa/exa.c
+++ b/exa/exa.c
@@ -660,6 +660,17 @@ exaDriverInit (ScreenPtr pScreen,
if (!pScreenInfo)
return FALSE;
+ if (pScreenInfo->exa_major != EXA_VERSION_MAJOR ||
+ pScreenInfo->exa_minor > EXA_VERSION_MINOR)
+ {
+ LogMessage(X_ERROR, "EXA(%d): driver's EXA version requirements "
+ "(%d.%d) are incompatible with EXA version (%d.%d)\n",
+ pScreen->myNum,
+ pScreenInfo->exa_major, pScreenInfo->exa_minor,
+ EXA_VERSION_MAJOR, EXA_VERSION_MINOR);
+ return FALSE;
+ }
+
if (!pScreenInfo->memoryBase) {
LogMessage(X_ERROR, "EXA(%d): ExaDriverRec::memoryBase must be "
"non-zero\n", pScreen->myNum);
@@ -696,17 +707,6 @@ exaDriverInit (ScreenPtr pScreen,
return FALSE;
}
- if (pScreenInfo->exa_major != EXA_VERSION_MAJOR ||
- pScreenInfo->exa_minor > EXA_VERSION_MINOR)
- {
- LogMessage(X_ERROR, "EXA(%d): driver's EXA version requirements "
- "(%d.%d) are incompatible with EXA version (%d.%d)\n",
- pScreen->myNum,
- pScreenInfo->exa_major, pScreenInfo->exa_minor,
- EXA_VERSION_MAJOR, EXA_VERSION_MINOR);
- return FALSE;
- }
-
#ifdef RENDER
ps = GetPictureScreenIfSet(pScreen);
#endif