/ Check-in [8b4cf33a]
Login

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

Overview
Comment:Add a missing call to free() in Lemon.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA3-256: 8b4cf33aafe09d9009119dcbd464b54be9605af5701002ee458819efa6e2e1f9
User & Date: mistachkin 2018-09-08 16:55:18
Context
2018-09-08
20:09
Fix multiple issues with the ORDER BY LIMIT optimization. This is the proposed resolution to ticket [9936b2fa443fec03ff25]. check-in: 20672012 user: drh tags: trunk
16:55
Add a missing call to free() in Lemon. check-in: 8b4cf33a user: mistachkin tags: trunk
16:53
Fix typo in the Win32-specific code for the fileio extension. check-in: e812e5d5 user: mistachkin tags: trunk
Changes
Hide Diffs Side-by-Side Diffs Ignore Whitespace Patch

Changes to tool/lemon.c.

  2851   2851     }
  2852   2852     fseek(fp,0,2);
  2853   2853     filesize = ftell(fp);
  2854   2854     rewind(fp);
  2855   2855     filebuf = (char *)malloc( filesize+1 );
  2856   2856     if( filesize>100000000 || filebuf==0 ){
  2857   2857       ErrorMsg(ps.filename,0,"Input file too large.");
         2858  +    free(filebuf);
  2858   2859       gp->errorcnt++;
  2859   2860       fclose(fp);
  2860   2861       return;
  2861   2862     }
  2862   2863     if( fread(filebuf,1,filesize,fp)!=filesize ){
  2863   2864       ErrorMsg(ps.filename,0,"Can't read in all %d bytes of this file.",
  2864   2865         filesize);