1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-11-11 01:42:22 +03:00

Improved handling of OOM while reallocating a column name to add type

information.  dbsqlfuzz 5a195b4233649e49e0aa34f1b743ca192d85b198

FossilOrigin-Name: 5995dd4de4997c43b43befc1281ef6378f33f781134c7f368299d64db2344f1d
This commit is contained in:
drh
2021-11-12 14:39:49 +00:00
parent 9135ebb7db
commit 146121f5cb
4 changed files with 13 additions and 9 deletions

View File

@@ -2209,6 +2209,9 @@ void sqlite3SelectAddColumnTypeAndCollation(
if( pCol->zCnName ){
memcpy(&pCol->zCnName[n+1], zType, m+1);
pCol->colFlags |= COLFLAG_HASTYPE;
}else{
testcase( pCol->colFlags & COLFLAG_HASTYPE );
pCol->colFlags &= ~(COLFLAG_HASTYPE|COLFLAG_HASCOLL);
}
}
if( pCol->affinity<=SQLITE_AFF_NONE ) pCol->affinity = aff;