/ Check-in [3f6730be]
Login

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

Overview
Comment:Quick patch to the Lemon parser template to avoid an array overread reported by OSSFuzz. A proper fix involves enhancements to the table generators in Lemon to make the overread impossible. That fix will take longer to implement. The current check-in is a stop-gap.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA3-256: 3f6730be4cb712a28401be6d96e56ccb3f2e98dd8961b477befec3f363715178
User & Date: drh 2018-07-01 16:05:40
Context
2018-07-02
12:07
Fix a segfault caused by invoking a regular aggregate as a window-function. And some problems with count(*) when used as a window-function. check-in: 4f3c8a82 user: dan tags: trunk
2018-07-01
16:05
Quick patch to the Lemon parser template to avoid an array overread reported by OSSFuzz. A proper fix involves enhancements to the table generators in Lemon to make the overread impossible. That fix will take longer to implement. The current check-in is a stop-gap. check-in: 3f6730be user: drh tags: trunk
2018-06-30
20:26
Avoid a warning in fts5.c due to not using generated routine sqlite3Fts5ParserFallback(). check-in: 65ff5144 user: dan tags: trunk
Changes
Hide Diffs Side-by-Side Diffs Ignore Whitespace Patch

Changes to tool/lempar.c.

   546    546           if( 
   547    547   #if YY_SHIFT_MIN+YYWILDCARD<0
   548    548             j>=0 &&
   549    549   #endif
   550    550   #if YY_SHIFT_MAX+YYWILDCARD>=YY_ACTTAB_COUNT
   551    551             j<YY_ACTTAB_COUNT &&
   552    552   #endif
          553  +          j<sizeof(yy_lookahead)/sizeof(yy_lookahead[0]) &&
   553    554             yy_lookahead[j]==YYWILDCARD && iLookAhead>0
   554    555           ){
   555    556   #ifndef NDEBUG
   556    557             if( yyTraceFILE ){
   557    558               fprintf(yyTraceFILE, "%sWILDCARD %s => %s\n",
   558    559                  yyTracePrompt, yyTokenName[iLookAhead],
   559    560                  yyTokenName[YYWILDCARD]);