mirror of
https://github.com/postgres/postgres.git
synced 2025-07-03 20:02:46 +03:00
Use outerPlanState macro instead of referring to leffttree.
This makes the executor code more consistent. It also removes an apparently superfluous NULL test in nodeGroup.c. Qingqing Zhou, reviewed by Tom Lane, and further revised by me.
This commit is contained in:
@ -280,6 +280,8 @@ ExecEndGroup(GroupState *node)
|
||||
void
|
||||
ExecReScanGroup(GroupState *node)
|
||||
{
|
||||
PlanState *outerPlan = outerPlanState(node);
|
||||
|
||||
node->grp_done = FALSE;
|
||||
node->ss.ps.ps_TupFromTlist = false;
|
||||
/* must clear first tuple */
|
||||
@ -289,7 +291,6 @@ ExecReScanGroup(GroupState *node)
|
||||
* if chgParam of subnode is not null then plan will be re-scanned by
|
||||
* first ExecProcNode.
|
||||
*/
|
||||
if (node->ss.ps.lefttree &&
|
||||
node->ss.ps.lefttree->chgParam == NULL)
|
||||
ExecReScan(node->ss.ps.lefttree);
|
||||
if (outerPlan->chgParam == NULL)
|
||||
ExecReScan(outerPlan);
|
||||
}
|
||||
|
Reference in New Issue
Block a user