diff options
author | Tom Lane <tgl@sss.pgh.pa.us> | 2021-03-20 12:38:22 -0400 |
---|---|---|
committer | Tom Lane <tgl@sss.pgh.pa.us> | 2021-03-20 12:38:22 -0400 |
commit | 992cba94d38ef20765e4c54e4dff00ae8a58a6c5 (patch) | |
tree | d713250513a71a063f63ef9e8f81be66f8992d5f /src/backend/access/transam/commit_ts.c | |
parent | 4eca51d4464133e6f4cd923355c6dd971d9c27d3 (diff) | |
download | postgresql-992cba94d38ef20765e4c54e4dff00ae8a58a6c5.tar.gz postgresql-992cba94d38ef20765e4c54e4dff00ae8a58a6c5.zip |
Fix memory leak when initializing DH parameters in backend
When loading DH parameters used for the generation of ephemeral DH keys
in the backend, the code has never bothered releasing the memory used
for the DH information loaded from a file or from libpq's default. This
commit makes sure that the information is properly free()'d.
Back-patch of e0e569e1d. We originally thought the leak was minor and
not worth back-patching, but Jelte Fennema pointed out that repeated
SIGHUP's can result in very serious bloat of the postmaster, which is
then multiplied by being duplicated into eadh forked child.
Back-patch to v10; the code looked different before c0a15e07c,
and didn't have a leak in the actually-live code paths.
Michael Paquier
Discussion: https://postgr.es/m/16160-18367e56e9a28264@postgresql.org
Diffstat (limited to 'src/backend/access/transam/commit_ts.c')
0 files changed, 0 insertions, 0 deletions