Hello
For some time already i noticed that when i use NEAR/1 and OR in one query like
SELECT * FROM search WHERE search MATCH 'tom NEAR/1 hanks or tom hanks'
i get out of memory error. Running this on 16Gb laptop cannot be memory issue
and the database only has several thousands of records. Investigating the code
i found one place where in fts3EvalNearTest where it happens:
line 129689 i version 3.7.14.1
nTmp += p->pPhrase->doclist.nList;
aTmp = sqlite3_malloc(nTmp*2);
if( !aTmp ){
Adding the check before the malloc solved the problem
if (nTmp <= 0) return res;
Thanks
_______________________________________________
sqlite-users mailing list
[email protected]
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users