From: Sarah Hoffmann Date: Wed, 12 Oct 2016 18:09:20 +0000 (+0200) Subject: reduce search depth when splitting word sets X-Git-Tag: v3.0.0~107 X-Git-Url: https://git.openstreetmap.org./nominatim.git/commitdiff_plain/c0b44113371bd40c74b90b0e49dc0ff63e672a4f reduce search depth when splitting word sets Too many out-of-memory conditions with the current algorithm. --- diff --git a/lib/lib.php b/lib/lib.php index 092965ba..e14f52f9 100644 --- a/lib/lib.php +++ b/lib/lib.php @@ -55,7 +55,7 @@ function getWordSets($aWords, $iDepth) { $aResult = array(array(join(' ', $aWords))); $sFirstToken = ''; - if ($iDepth < 8) { + if ($iDepth < 7) { while (sizeof($aWords) > 1) { $sWord = array_shift($aWords); $sFirstToken .= ($sFirstToken?' ':'').$sWord;