Re: Memory leak with XLogFileCopy since de768844 (WAL file with .partial) - Mailing list pgsql-hackers

From Michael Paquier
Subject Re: Memory leak with XLogFileCopy since de768844 (WAL file with .partial)
Date
Msg-id CAB7nPqQ9E3nbaYz8QuWezuOiOs03yOyqLUcQd6uuF3DgiQakOA@mail.gmail.com
Whole thread Raw
In response to Re: Memory leak with XLogFileCopy since de768844 (WAL file with .partial)  (Fujii Masao <masao.fujii@gmail.com>)
Responses Re: Memory leak with XLogFileCopy since de768844 (WAL file with .partial)  (Fujii Masao <masao.fujii@gmail.com>)
List pgsql-hackers
On Fri, Jun 5, 2015 at 10:45 PM, Fujii Masao wrote:
> Why don't we call InstallXLogFileSegment() at the end of XLogFileCopy()?
> If we do that, the risk of memory leak you're worried will disappear at all.

Yes, that looks fine, XLogFileCopy() would copy to a temporary file,
then install it definitely. Updated patch attached.
--
Michael

Attachment

pgsql-hackers by date:

Previous
From: Alvaro Herrera
Date:
Subject: Re: [CORE] Restore-reliability mode
Next
From: Abhijit Menon-Sen
Date:
Subject: skipping pg_log in basebackup (was Re: pg_basebackup and pg_stat_tmp directory)