Skip to content

Commit 6c1abf0

Browse files
author
Thomas G. Lockhart
committed
Fix from Vadim for simple-minded case SELECT 1 WHERE 1 IN (SELECT 1)
used in regression tests. No longer core dumps.
1 parent 1aa93cb commit 6c1abf0

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/backend/executor/nodeResult.c

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727
* SeqScan (emp.all)
2828
*
2929
* IDENTIFICATION
30-
* $Header: /cvsroot/pgsql/src/backend/executor/nodeResult.c,v 1.6 1998/02/13 03:26:52 vadim Exp $
30+
* $Header: /cvsroot/pgsql/src/backend/executor/nodeResult.c,v 1.7 1998/02/18 07:19:34 thomas Exp $
3131
*
3232
*-------------------------------------------------------------------------
3333
*/
@@ -291,7 +291,8 @@ ExecReScanResult(Result *node, ExprContext *exprCtxt, Plan *parent)
291291
* if chgParam of subnode is not null then plan
292292
* will be re-scanned by first ExecProcNode.
293293
*/
294-
if (((Plan*) node)->lefttree->chgParam == NULL)
294+
if (((Plan*) node)->lefttree &&
295+
((Plan*) node)->lefttree->chgParam == NULL)
295296
ExecReScan (((Plan*) node)->lefttree, exprCtxt, (Plan *) node);
296297

297298
}

0 commit comments

Comments
 (0)