From: Michael Paquier <michael@paquier.xyz>
To: Joe Conway <mail@joeconway.com>
Cc: Postgres hackers <pgsql-hackers@lists.postgresql.org>
Subject: Re: Tighten error control for OpenTransientFile/CloseTransientFile
Date: Sat, 2 Mar 2019 09:40:22 +0900
Message-ID: <20190302004022.GA1602@paquier.xyz> (raw)
In-Reply-To: <09ffc3a3-0e1d-91c6-7748-890b1829469a@joeconway.com>
References: <20190301023338.GD1348@paquier.xyz>
<09ffc3a3-0e1d-91c6-7748-890b1829469a@joeconway.com>
On Fri, Mar 01, 2019 at 05:05:54PM -0500, Joe Conway wrote:
> Seems like it would be better to modify the arguments to
> CloseTransientFile() to include the filename being closed, errorlevel,
> and fail_on_error or something similar. Then all the repeated ereport
> stanzas could be eliminated.
Sure. Now some code paths close file descriptors without having at
hand the file name, which would mean that we'd need to pass NULL as
argument in this case. That's not really elegant in my opinion. And
having a consistent mapping with the system's close() is not really
bad to me either..
--
Michael
Attachments:
signature.asc (application/pgp-signature, 832B) download
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-hackers@postgresql.org
Cc: michael@paquier.xyz, mail@joeconway.com, pgsql-hackers@lists.postgresql.org
Subject: Re: Tighten error control for OpenTransientFile/CloseTransientFile
In-Reply-To: <20190302004022.GA1602@paquier.xyz>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox