aboutsummaryrefslogtreecommitdiff
path: root/src/backend/executor/execScan.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/backend/executor/execScan.c')
-rw-r--r--src/backend/executor/execScan.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/backend/executor/execScan.c b/src/backend/executor/execScan.c
index 3faf7f9a77d..d73d101f88d 100644
--- a/src/backend/executor/execScan.c
+++ b/src/backend/executor/execScan.c
@@ -355,6 +355,12 @@ ExecScanReScan(ScanState *node)
/* Stop projecting any tuples from SRFs in the targetlist */
node->ps.ps_TupFromTlist = false;
+ /*
+ * We must clear the scan tuple so that observers (e.g., execCurrent.c)
+ * can tell that this plan node is not positioned on a tuple.
+ */
+ ExecClearTuple(node->ss_ScanTupleSlot);
+
/* Rescan EvalPlanQual tuple if we're inside an EvalPlanQual recheck */
if (estate->es_epqScanDone != NULL)
{