From: Sarah Hoffmann Date: Wed, 29 Oct 2014 20:04:28 +0000 (+0100) Subject: only check for postgres major and minor version X-Git-Tag: v2.4.0~73 X-Git-Url: https://git.openstreetmap.org./nominatim.git/commitdiff_plain/8f09b9378f29f7180fa1d31bc7392b4945f23d29?hp=-c only check for postgres major and minor version fixes #192 --- 8f09b9378f29f7180fa1d31bc7392b4945f23d29 diff --git a/utils/setup.php b/utils/setup.php index c07bccef..42a132bf 100755 --- a/utils/setup.php +++ b/utils/setup.php @@ -112,7 +112,7 @@ $oDB =& getDB(); $sVersionString = $oDB->getOne('select version()'); - preg_match('#PostgreSQL ([0-9]+)[.]([0-9]+)[.]([0-9]+) #', $sVersionString, $aMatches); + preg_match('#PostgreSQL ([0-9]+)[.]([0-9]+)[^0-9]#', $sVersionString, $aMatches); if (CONST_Postgresql_Version != $aMatches[1].'.'.$aMatches[2]) { echo "ERROR: PostgreSQL version is not correct. Expected ".CONST_Postgresql_Version." found ".$aMatches[1].'.'.$aMatches[2]."\n";