1
0
Fork 0

fixed version expectation

This commit is contained in:
Jan Steemann 2014-02-28 10:26:43 +01:00
parent c4cfe7a2ea
commit abd11203c3
2 changed files with 10 additions and 6 deletions

View File

@ -928,9 +928,11 @@ int main (int argc, char* argv[]) {
TRI_EXIT_FUNCTION(EXIT_FAILURE, NULL); TRI_EXIT_FUNCTION(EXIT_FAILURE, NULL);
} }
if (major != 1 || if (major < 1 ||
(major == 1 && minor < 4)) { major > 2 ||
// we can connect to 1.4 and higher only (major == 1 && minor < 4) ||
(major == 2 && minor > 0)) {
// we can connect to 1.4, 2.0 and higher only
cerr << "Got an incompatible server version '" << versionString << "'" << endl; cerr << "Got an incompatible server version '" << versionString << "'" << endl;
TRI_EXIT_FUNCTION(EXIT_FAILURE, NULL); TRI_EXIT_FUNCTION(EXIT_FAILURE, NULL);
} }

View File

@ -921,9 +921,11 @@ int main (int argc, char* argv[]) {
TRI_EXIT_FUNCTION(EXIT_FAILURE, NULL); TRI_EXIT_FUNCTION(EXIT_FAILURE, NULL);
} }
if (major != 1 || if (major < 1 ||
(major == 1 && minor < 4)) { major > 2 ||
// we can connect to 1.4 and higher only (major == 1 && minor < 4) ||
(major == 2 && minor > 0)) {
// we can connect to 1.4, 2.0 and higher only
cerr << "Got an incompatible server version '" << versionString << "'" << endl; cerr << "Got an incompatible server version '" << versionString << "'" << endl;
TRI_EXIT_FUNCTION(EXIT_FAILURE, NULL); TRI_EXIT_FUNCTION(EXIT_FAILURE, NULL);
} }