---------------------------------------------------------------- * ExecEndHashJoin * * clean up routine for HashJoin node * ---------------------------------------------------------------- */
| 1029 | * ---------------------------------------------------------------- |
| 1030 | */ |
| 1031 | void |
| 1032 | ExecEndHashJoin(HashJoinState *node) |
| 1033 | { |
| 1034 | /* |
| 1035 | * Free hash table |
| 1036 | */ |
| 1037 | if (node->hj_HashTable) |
| 1038 | { |
| 1039 | if (!node->hj_HashTable->eagerlyReleased) |
| 1040 | { |
| 1041 | HashState *hashState = (HashState *) innerPlanState(node); |
| 1042 | |
| 1043 | ExecHashTableDestroy(hashState, node->hj_HashTable); |
| 1044 | } |
| 1045 | pfree(node->hj_HashTable); |
| 1046 | node->hj_HashTable = NULL; |
| 1047 | } |
| 1048 | |
| 1049 | /* |
| 1050 | * Free the exprcontext |
| 1051 | */ |
| 1052 | ExecFreeExprContext(&node->js.ps); |
| 1053 | |
| 1054 | /* |
| 1055 | * clean out the tuple table |
| 1056 | */ |
| 1057 | ExecClearTuple(node->js.ps.ps_ResultTupleSlot); |
| 1058 | ExecClearTuple(node->hj_OuterTupleSlot); |
| 1059 | ExecClearTuple(node->hj_HashTupleSlot); |
| 1060 | |
| 1061 | /* |
| 1062 | * clean up subtrees |
| 1063 | */ |
| 1064 | ExecEndNode(outerPlanState(node)); |
| 1065 | ExecEndNode(innerPlanState(node)); |
| 1066 | } |
| 1067 | |
| 1068 | /* |
| 1069 | * ExecHashJoinOuterGetTuple |
no test coverage detected