Improvements to the way that OOM errors are processed.

FossilOrigin-Name: c3ef03478a5788c855b3aef385d43ae7f494f440
diff --git a/src/expr.c b/src/expr.c
index c91db28..5b134d6 100644
--- a/src/expr.c
+++ b/src/expr.c
@@ -699,7 +699,10 @@
       if( x>pParse->nzVar ){
         char **a;
         a = sqlite3DbRealloc(db, pParse->azVar, x*sizeof(a[0]));
-        if( a==0 ) return;  /* Error reported through db->mallocFailed */
+        if( a==0 ){
+          assert( db->mallocFailed ); /* Error reported through mallocFailed */
+          return;
+        }
         pParse->azVar = a;
         memset(&a[pParse->nzVar], 0, (x-pParse->nzVar)*sizeof(a[0]));
         pParse->nzVar = x;