1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-08-08 14:02:16 +03:00

Avoid an assert() failure that could occur in SQLITE_ENABLE_UPDATE_DELETE_LIMIT builds when a WITH clause attached to an UPDATE or DELETE statement created a CTE of the same name as the table being modified.

FossilOrigin-Name: 8edf56d1698c3db38250db3b25864f658488414efb3a6b3e1443283b6affd26d
This commit is contained in:
dan
2023-05-17 11:31:51 +00:00
parent 010bd47b98
commit 32a5feb53e
5 changed files with 42 additions and 11 deletions

View File

@@ -224,7 +224,7 @@ static void updateFromSelect(
assert( pTabList->nSrc>1 );
if( pSrc ){
pSrc->a[0].fg.notCte = 1;
assert( pSrc->a[0].fg.notCte );
pSrc->a[0].iCursor = -1;
pSrc->a[0].pTab->nTabRef--;
pSrc->a[0].pTab = 0;