diff options
author | drh <drh@noemail.net> | 2018-03-30 15:59:54 +0000 |
---|---|---|
committer | drh <drh@noemail.net> | 2018-03-30 15:59:54 +0000 |
commit | 9f95e48d94f0a3c9354d3e394b498561e7e83764 (patch) | |
tree | c03db953b4ff577e57c0a25e890a7ad012ccfb3d /ext/misc/spellfix.c | |
parent | d99f49fcc98005fde188a9adc171f6acad897360 (diff) | |
download | sqlite-9f95e48d94f0a3c9354d3e394b498561e7e83764.tar.gz sqlite-9f95e48d94f0a3c9354d3e394b498561e7e83764.zip |
Fix an off-by-one error in the dist3 algorithm of the spellfix extension.
FossilOrigin-Name: 5c34af7b975598bbe20751dfdd346f43031cb2bcb6b78f1bbdb2b51b398de182
Diffstat (limited to 'ext/misc/spellfix.c')
-rw-r--r-- | ext/misc/spellfix.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/ext/misc/spellfix.c b/ext/misc/spellfix.c index 8651bb7a9..e2364fe5b 100644 --- a/ext/misc/spellfix.c +++ b/ext/misc/spellfix.c @@ -764,7 +764,7 @@ static int editDist3ConfigLoad( assert( zTo!=0 || nTo==0 ); if( nFrom>100 || nTo>100 ) continue; if( iCost<0 ) continue; - if( iCost>10000 ) continue; /* Costs above 10K are considered infinite */ + if( iCost>=10000 ) continue; /* Costs above 10K are considered infinite */ if( pLang==0 || iLang!=iLangPrev ){ EditDist3Lang *pNew; pNew = sqlite3_realloc64(p->a, (p->nLang+1)*sizeof(p->a[0])); |