Make sure the WhereTerm objects are fully zeroed when they are allocated.

FossilOrigin-Name: fdb667335c2250239a66143aec4235325dec8274
This commit is contained in:
drh 2014-12-05 19:50:58 +00:00
parent ebdb81dd45
commit fe32daaeaa
3 changed files with 8 additions and 8 deletions

View File

@ -1,5 +1,5 @@
C The\sKeyInfo\scache\smust\sbe\scleared\sbefore\sclosing\sthe\sbtree,\snot\safter.\nRevised\sfix\sfor\sticket\s[e4a18565a36884b00edf].
D 2014-12-05T15:31:33.761
C Make\ssure\sthe\sWhereTerm\sobjects\sare\sfully\szeroed\swhen\sthey\sare\sallocated.
D 2014-12-05T19:50:58.294
F Makefile.arm-wince-mingw32ce-gcc d6df77f1f48d690bd73162294bbba7f59507c72f
F Makefile.in 6c4f961fa91d0b4fa121946a19f9e5eac2f2f809
F Makefile.linux-gcc 91d710bdc4998cb015f39edf3cb314ec4f4d7e23
@ -304,7 +304,7 @@ F src/vtab.c c08ec66f45919eaa726bf88aa53eb08379d607f9
F src/wal.c 847692349eb6e1fb8543dbc97e69ddbfa4cc7ea7
F src/wal.h df01efe09c5cb8c8e391ff1715cca294f89668a4
F src/walker.c c253b95b4ee44b21c406e2a1052636c31ea27804
F src/where.c d67fe69dd1bb32ad3d488a8c5bc803a29814f357
F src/where.c 8877b55e6803eaa856254875bca8d12fff3681cf
F src/whereInt.h d3633e9b592103241b74b0ec76185f3e5b8b62e0
F test/8_3_names.test ebbb5cd36741350040fd28b432ceadf495be25b2
F test/aggerror.test a867e273ef9e3d7919f03ef4f0e8c0d2767944f2
@ -1224,8 +1224,7 @@ F tool/vdbe_profile.tcl 67746953071a9f8f2f668b73fe899074e2c6d8c1
F tool/warnings-clang.sh f6aa929dc20ef1f856af04a730772f59283631d4
F tool/warnings.sh 0abfd78ceb09b7f7c27c688c8e3fe93268a13b32
F tool/win/sqlite.vsix deb315d026cc8400325c5863eef847784a219a2f
P adca7688de20ff40d8ddf2107dfaf92af3873b83
Q +48529508cfe2f9445a6940222fe5ff7cc92aef78
R 943a66e258c43484e6287cfb624784df
P 7ed3346e8c10dbf52fd44ab69900699d4f7ad3fd
R 4b33ce7227bf5d27f48a35be658eb882
U drh
Z 9be13842ba3000b4a28c2a5894f2ade5
Z 1360efaa2c5f7305d23abadc41fbb137

View File

@ -1 +1 @@
7ed3346e8c10dbf52fd44ab69900699d4f7ad3fd
fdb667335c2250239a66143aec4235325dec8274

View File

@ -222,6 +222,7 @@ static int whereClauseInsert(WhereClause *pWC, Expr *p, u8 wtFlags){
sqlite3DbFree(db, pOld);
}
pWC->nSlot = sqlite3DbMallocSize(db, pWC->a)/sizeof(pWC->a[0]);
memset(&pWC->a[pWC->nTerm], 0, sizeof(pWC->a[0])*(pWC->nSlot-pWC->nTerm));
}
pTerm = &pWC->a[idx = pWC->nTerm++];
if( p && ExprHasProperty(p, EP_Unlikely) ){