]> git.ipfire.org Git - thirdparty/postgresql.git/commit
Fix memory leaks in pg_combinebackup/reconstruct.c.
authorTom Lane <tgl@sss.pgh.pa.us>
Wed, 22 Oct 2025 17:38:37 +0000 (13:38 -0400)
committerTom Lane <tgl@sss.pgh.pa.us>
Wed, 22 Oct 2025 17:38:37 +0000 (13:38 -0400)
commite2072b47b9abc7d298d242217919d3d0d9415fca
treed0cbdf0e18f81e0b41941f7724e838c6d3a82431
parent6ff7ba9fe525fd64cdafb242867d8d22486b88d9
Fix memory leaks in pg_combinebackup/reconstruct.c.

One code path forgot to free the separately-malloc'd filename
part of a struct rfile.  Another place freed the filename but
forgot the struct rfile itself.  These seem worth fixing because
with a large backup we could be dealing with many files.

Coverity found the bug in make_rfile().  I found the other one
by manual inspection.
src/bin/pg_combinebackup/reconstruct.c