Re: Errands around AllocateDir() - Mailing list pgsql-hackers

From Alvaro Herrera
Subject Re: Errands around AllocateDir()
Date
Msg-id 20171204191134.2cpxmvvn7fkwaze5@alvherre.pgsql
Whole thread Raw
In response to Re: Errands around AllocateDir()  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: Errands around AllocateDir()  (Michael Paquier <michael.paquier@gmail.com>)
List pgsql-hackers
Tom Lane wrote:

> Yeah, agreed.  The only thing I'm concerned about back-patching is
> the places where a wrong errno might be reported.

If we're currently reporting "could not open dir: Success" then
backpatching such a fix is definitely an improvement.  OTOH if currently
we have opendir() trying to report a failure, then LWLockRelease replace
the errno because something completely unrelated also failed, having the
message report exactly the opendir() failure rather than the lwlock
failure is surely also an improvement.

-- 
Álvaro Herrera                https://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services


pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: Errands around AllocateDir()
Next
From: Tom Lane
Date:
Subject: Is it OK to ignore directory open failure in ResetUnloggedRelations?