Fix another problem in lead()/lag(). And some errors that could occur

following OOM faults.

FossilOrigin-Name: fadd4dc119d8df0d871f4d839b7a11070e2ffb8927e84b3e7a94f34196db3de3
This commit is contained in:
dan
2018-06-15 19:01:35 +00:00
parent e0a5e20fa8
commit 6fde1799f8
7 changed files with 146 additions and 15 deletions
+5 -1
View File
@@ -535,7 +535,11 @@ oneselect(A) ::= SELECT(S) distinct(D) selcollist(W) from(X) where_opt(Y)
Token s = S; /*A-overwrites-S*/
#endif
A = sqlite3SelectNew(pParse,W,X,Y,P,Q,Z,D,L);
if( A ) A->pWinDefn = R;
if( A ){
A->pWinDefn = R;
}else{
sqlite3WindowListDelete(pParse->db, R);
}
#if SELECTTRACE_ENABLED
/* Populate the Select.zSelName[] string that is used to help with
** query planner debugging, to differentiate between multiple Select