Thread: pgsql: Error out in pg_rewind if lstat() fails.

pgsql: Error out in pg_rewind if lstat() fails.

From
Heikki Linnakangas
Date:
Error out in pg_rewind if lstat() fails.

A "file not found" is expected if the source server is running, so don't
complain about that. But any other error is definitely not expected.

Branch
------
master

Details
-------
http://git.postgresql.org/pg/commitdiff/b5e560c24603e5325a81055c8f36cc45d48609e4

Modified Files
--------------
src/bin/pg_rewind/copy_fetch.c |   25 ++++++++++++++-----------
1 file changed, 14 insertions(+), 11 deletions(-)


Re: pgsql: Error out in pg_rewind if lstat() fails.

From
Michael Paquier
Date:
On Thu, Apr 16, 2015 at 5:15 AM, Heikki Linnakangas
<heikki.linnakangas@iki.fi> wrote:
> Error out in pg_rewind if lstat() fails.
>
> A "file not found" is expected if the source server is running, so don't
> complain about that. But any other error is definitely not expected.

Nitpicking: strings of pg_fatal need to have a newline '\n' for readability.
--
Michael


Re: pgsql: Error out in pg_rewind if lstat() fails.

From
Heikki Linnakangas
Date:
On 04/16/2015 04:17 AM, Michael Paquier wrote:
> On Thu, Apr 16, 2015 at 5:15 AM, Heikki Linnakangas
> <heikki.linnakangas@iki.fi> wrote:
>> Error out in pg_rewind if lstat() fails.
>>
>> A "file not found" is expected if the source server is running, so don't
>> complain about that. But any other error is definitely not expected.
>
> Nitpicking: strings of pg_fatal need to have a newline '\n' for readability.

Ah, good catch! Fixed.

- Heikki