mirror of
https://github.com/sqlite/sqlite.git
synced 2025-11-03 16:53:36 +03:00
Avoid misaligned memory allocations on Sparc in sqlite3VdbeMakeReady().
FossilOrigin-Name: a304e34675404aee860fcc97fa4ffcc57c014812
This commit is contained in:
@@ -1849,9 +1849,8 @@ void sqlite3VdbeMakeReady(
|
||||
/* Allocate space for memory registers, SQL variables, VDBE cursors and
|
||||
** an array to marshal SQL function arguments in.
|
||||
*/
|
||||
zCsr = (u8*)&p->aOp[p->nOp]; /* Memory avaliable for allocation */
|
||||
assert( pParse->nOpAlloc*sizeof(Op) <= 0x7fffff00 );
|
||||
nFree = (pParse->nOpAlloc - p->nOp)*sizeof(p->aOp[0]); /* Available space */
|
||||
zCsr = ((u8*)p->aOp) + ROUND8(sizeof(Op)*p->nOp); /* Available space */
|
||||
nFree = sqlite3_msize(p->aOp) - ROUND8(sizeof(Op)*p->nOp); /* Size of zCsr */
|
||||
|
||||
resolveP2Values(p, &nArg);
|
||||
p->usesStmtJournal = (u8)(pParse->isMultiWrite && pParse->mayAbort);
|
||||
|
||||
Reference in New Issue
Block a user