aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authordrh <drh@noemail.net>2015-12-03 21:47:30 +0000
committerdrh <drh@noemail.net>2015-12-03 21:47:30 +0000
commit9802947fd88ece99796b444e06f918b6578fe3ab (patch)
tree0f99b01c4ff7d2ed147c920a98a44daac6b16b5c /src
parent7a7f688979fafb7f345db9463d8b8991606ba410 (diff)
downloadsqlite-9802947fd88ece99796b444e06f918b6578fe3ab.tar.gz
sqlite-9802947fd88ece99796b444e06f918b6578fe3ab.zip
Improved OOM recovery in the SELECT code generator logic.
FossilOrigin-Name: e6521a436d464a42b87a7d5ba5cc98235b92440a
Diffstat (limited to 'src')
-rw-r--r--src/select.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/select.c b/src/select.c
index fca8665cd..f8b8e9e77 100644
--- a/src/select.c
+++ b/src/select.c
@@ -1529,8 +1529,9 @@ static void generateColumnNames(
}
#endif
+ if( pParse->colNamesSet || db->mallocFailed ) return;
+ assert( v!=0 );
assert( pTabList!=0 );
- if( pParse->colNamesSet || NEVER(v==0) || db->mallocFailed ) return;
pParse->colNamesSet = 1;
fullNames = (db->flags & SQLITE_FullColNames)!=0;
shortNames = (db->flags & SQLITE_ShortColNames)!=0;