Re: Refactor backup related code (was: Is it correct to say, "invalid data in file \"%s\"", BACKUP_LABEL_FILE in do_pg_backup_stop?) - Mailing list pgsql-hackers
From
Michael Paquier
Subject
Re: Refactor backup related code (was: Is it correct to say, "invalid data in file \"%s\"", BACKUP_LABEL_FILE in do_pg_backup_stop?)
On Mon, Sep 26, 2022 at 11:57:58AM +0530, Bharath Rupireddy wrote:
> +1 because callers don't use returned StringInfo structure outside of
> build_backup_content(). The patch looks good to me.
Thanks for looking.
> I think it will be
> good to add a note about the caller freeing up the retired string's
> memory [1], just in case.
Not sure that this is worth it. It is fine to use palloc() in a
dedicated memory context, for one.
--
Michael