pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Michael Paquier <michael@paquier.xyz>
Cc: Postgres hackers <pgsql-hackers@postgresql.org>
Cc: Peter Eisentraut <peter.eisentraut@2ndquadrant.com>
Subject: Re: pgsql: Fix failure to check for open() or fsync() failures.
Date: Wed, 26 Dec 2018 20:35:22 -0500
Message-ID: <32282.1545874522@sss.pgh.pa.us> (raw)
In-Reply-To: <20181227010918.GC2106@paquier.xyz>
References: <E1gcGPf-0000Ih-1f@gemulon.postgresql.org>
	<20181226224351.GA2106@paquier.xyz>
	<26009.1545864936@sss.pgh.pa.us>
	<20181227010918.GC2106@paquier.xyz>

Michael Paquier <michael@paquier.xyz> writes:
> On Wed, Dec 26, 2018 at 05:55:36PM -0500, Tom Lane wrote:
>> It appears to me that the code is intentionally not worrying about
>> fsync failure, so it seems wrong for it to FATAL out if it's unable
>> to open the file to fsync it.  And it surely shouldn't do so if the
>> file isn't there.

> My point is a bit different though: it seems to me that we could just
> call BasicOpenFilePerm() and remove the stat() to do exactly the same
> things, simplifying the code.

Oh, I see.  Yeah, if we're ignoring errors anyway, the stat calls
seem redundant.

			regards, tom lane




view thread (7+ messages)  latest in thread

Message-ID: <32282.1545874522@sss.pgh.pa.us>
Permalink:  ../32282.1545874522@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/32282.1545874522@sss.pgh.pa.us

 · 

reply

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 from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-committers@postgresql.org
  Cc: tgl@sss.pgh.pa.us, michael@paquier.xyz, pgsql-hackers@postgresql.org, peter.eisentraut@2ndquadrant.com
  Subject: Re: pgsql: Fix failure to check for open() or fsync() failures.
  In-Reply-To: <32282.1545874522@sss.pgh.pa.us>
  References: <E1gcGPf-0000Ih-1f@gemulon.postgresql.org> <20181226224351.GA2106@paquier.xyz> <26009.1545864936@sss.pgh.pa.us> <20181227010918.GC2106@paquier.xyz> <32282.1545874522@sss.pgh.pa.us>

* 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