forked frompostgres/postgres
- Notifications
You must be signed in to change notification settings - Fork6
Commitbcf2dec
committed
Fix minor memory leak in ident_inet().
We'd leak the ident_serv data structure if the second pg_getaddrinfo_all(the one for the local address) failed. This is not of great consequencebecause a failure return here just leads directly to backend exit(), butif this function is going to try to clean up after itself at all, it shouldnot have such holes in the logic. Try to fix it in a future-proof way byhaving all the failure exits go through the same cleanup path, rather than"optimizing" some of them.Per Coverity. Back-patch to 9.2, which is as far back as this patchapplies cleanly.1 parent5ea8cfe commitbcf2dec
1 file changed
+11
-10
lines changedLines changed: 11 additions & 10 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
1616 | 1616 |
| |
1617 | 1617 |
| |
1618 | 1618 |
| |
1619 |
| - | |
1620 |
| - | |
| 1619 | + | |
1621 | 1620 |
| |
1622 | 1621 |
| |
1623 | 1622 |
| |
| |||
1656 | 1655 |
| |
1657 | 1656 |
| |
1658 | 1657 |
| |
1659 |
| - | |
1660 |
| - | |
1661 |
| - | |
| 1658 | + | |
| 1659 | + | |
| 1660 | + | |
1662 | 1661 |
| |
1663 | 1662 |
| |
1664 | 1663 |
| |
| |||
1672 | 1671 |
| |
1673 | 1672 |
| |
1674 | 1673 |
| |
1675 |
| - | |
1676 |
| - | |
1677 |
| - | |
| 1674 | + | |
| 1675 | + | |
| 1676 | + | |
1678 | 1677 |
| |
1679 | 1678 |
| |
1680 | 1679 |
| |
| |||
1761 | 1760 |
| |
1762 | 1761 |
| |
1763 | 1762 |
| |
1764 |
| - | |
1765 |
| - | |
| 1763 | + | |
| 1764 | + | |
| 1765 | + | |
| 1766 | + | |
1766 | 1767 |
| |
1767 | 1768 |
| |
1768 | 1769 |
| |
|
0 commit comments
Comments
(0)