Re: get_controlfile() can leak fds in the backend

Michael Paquier <michael@paquier.xyz>

From: Michael Paquier <michael@paquier.xyz>
To: Joe Conway <mail@joeconway.com>
Cc: Postgres hackers <pgsql-hackers@lists.postgresql.org>
Date: 2019-02-28T12:20:59Z
Lists: pgsql-hackers
On Thu, Feb 28, 2019 at 07:11:04AM -0500, Joe Conway wrote:
> Sure, will do. What are your thoughts on backpatching? This seems
> unlikely to be a practical concern in the field, so my inclination is a
> master only fix.

I agree that this would unlikely become an issue as an error on the
control file would most likely be a PANIC when updating it, so fixing
only HEAD sounds fine to me.  Thanks for asking!
--
Michael

Commits

  1. Tighten use of OpenTransientFile and CloseTransientFile

  2. Make get_controlfile not leak file descriptors