/ Check-in [eee02502]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Fix memory leak reported by an fts1 user. Was losing a doclist on a query error. (CVS 4347)
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: eee025024972852990e704253d1443c1cefb376c
User & Date: shess 2007-08-30 19:56:38
Context
2007-08-30
20:01
Fix discrepency in the test pointed out by a user. Was testing fts2 :-). (CVS 4348) check-in: 65c62ed8 user: shess tags: trunk
19:56
Fix memory leak reported by an fts1 user. Was losing a doclist on a query error. (CVS 4347) check-in: eee02502 user: shess tags: trunk
17:15
Make mutex functions available to loadable extensions. Fix the amalgamation generator to include the latest source files. (CVS 4346) check-in: 293a3f83 user: drh tags: trunk
Changes
Hide Diffs Side-by-Side Diffs Ignore Whitespace Patch

Changes to ext/fts1/fts1.c.

  2569   2569     DocList **ppResult    /* Write the result here */
  2570   2570   ){
  2571   2571     DocList *pLeft, *pRight, *pNew;
  2572   2572     int i, rc;
  2573   2573   
  2574   2574     pLeft = docListNew(DL_POSITIONS);
  2575   2575     rc = term_select_all(v, iColumn, pQTerm->pTerm, pQTerm->nTerm, pLeft);
  2576         -  if( rc ) return rc;
         2576  +  if( rc ){
         2577  +    docListDelete(pLeft);
         2578  +    return rc;
         2579  +  }
  2577   2580     for(i=1; i<=pQTerm->nPhrase; i++){
  2578   2581       pRight = docListNew(DL_POSITIONS);
  2579   2582       rc = term_select_all(v, iColumn, pQTerm[i].pTerm, pQTerm[i].nTerm, pRight);
  2580   2583       if( rc ){
  2581   2584         docListDelete(pLeft);
  2582   2585         return rc;
  2583   2586       }