aboutsummaryrefslogtreecommitdiff
path: root/src/wherecode.c
diff options
context:
space:
mode:
authordrh <>2022-04-09 03:06:01 +0000
committerdrh <>2022-04-09 03:06:01 +0000
commitf8bdcfa3f17dead618d9f4f3d680f7a5cba4083b (patch)
treeba6f2d214390eb963b21ad5d97e8d9f5019701af /src/wherecode.c
parent7d0ae00361386f87d179916d5abc6c11d3c85330 (diff)
downloadsqlite-f8bdcfa3f17dead618d9f4f3d680f7a5cba4083b.tar.gz
sqlite-f8bdcfa3f17dead618d9f4f3d680f7a5cba4083b.zip
The sqlite3WhereMalloc() routine allocates memory that is automatically
deleted when the corresponding WhereInfo object is destroyed. FossilOrigin-Name: f237e1d8cc41b937f34288daebfacf5f7b0990a807a805e0cb6b45bc730192d6
Diffstat (limited to 'src/wherecode.c')
-rw-r--r--src/wherecode.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/wherecode.c b/src/wherecode.c
index bab514a69..561b34fc8 100644
--- a/src/wherecode.c
+++ b/src/wherecode.c
@@ -640,8 +640,9 @@ static int codeEqualityTerm(
i = pLevel->u.in.nIn;
pLevel->u.in.nIn += nEq;
pLevel->u.in.aInLoop =
- sqlite3DbReallocOrFree(pParse->db, pLevel->u.in.aInLoop,
- sizeof(pLevel->u.in.aInLoop[0])*pLevel->u.in.nIn);
+ sqlite3WhereRealloc(pTerm->pWC->pWInfo,
+ pLevel->u.in.aInLoop,
+ sizeof(pLevel->u.in.aInLoop[0])*pLevel->u.in.nIn);
pIn = pLevel->u.in.aInLoop;
if( pIn ){
int iMap = 0; /* Index in aiMap[] */