forked frompostgres/postgres
- Notifications
You must be signed in to change notification settings - Fork6
Commitc556b29
Neil Conway
Fix a gradual memory leak in ExecReScanAgg(). Because the aggregation
hash table is allocated in a child context of the agg node's memorycontext, MemoryContextReset() will reset but *not* delete the childcontext. Since ExecReScanAgg() proceeds to build a new hash tablefrom scratch (in a new sub-context), this results in leaking theheader for the previous memory context. Therefore, useMemoryContextResetAndDeleteChildren() instead.Credit: My colleague Sailesh Krishnamurthy at Truviso for isolatingthe cause of the leak.1 parentaf1022d commitc556b29
1 file changed
+9
-3
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
61 | 61 | | |
62 | 62 | | |
63 | 63 | | |
64 | | - | |
| 64 | + | |
65 | 65 | | |
66 | 66 | | |
67 | 67 | | |
| |||
1646 | 1646 | | |
1647 | 1647 | | |
1648 | 1648 | | |
1649 | | - | |
1650 | | - | |
| 1649 | + | |
| 1650 | + | |
| 1651 | + | |
| 1652 | + | |
| 1653 | + | |
| 1654 | + | |
| 1655 | + | |
| 1656 | + | |
1651 | 1657 | | |
1652 | 1658 | | |
1653 | 1659 | | |
| |||
0 commit comments
Comments
(0)