From 6eb546795720d793e290a9c651f4e6440abf06be Mon Sep 17 00:00:00 2001 From: handa Date: Thu, 22 Oct 2009 04:10:04 +0000 Subject: [PATCH] (check_version): Fix the check. --- src/database.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/database.c b/src/database.c index 8844f09..853d583 100644 --- a/src/database.c +++ b/src/database.c @@ -551,11 +551,11 @@ check_version (MText *version) break; ver[i] = ver[i] * 10 + (*verstr - '0'); } - return (ver[0] < M17NLIB_MAJOR_VERSION + return (ver[0] > M17NLIB_MAJOR_VERSION || (ver[0] == M17NLIB_MAJOR_VERSION - && (ver[1] < M17NLIB_MINOR_VERSION + && (ver[1] > M17NLIB_MINOR_VERSION || (ver[1] == M17NLIB_MINOR_VERSION - && ver[2] <= M17NLIB_PATCH_LEVEL)))); + && ver[2] >= M17NLIB_PATCH_LEVEL)))); } static MDatabase * -- 1.7.10.4