Re: invalid data in file backup_label problem on windows - Mailing list pgsql-hackers

From Magnus Hagander
Subject Re: invalid data in file backup_label problem on windows
Date
Msg-id CABUevEw3aqgdngE9hVF7FT5t4sWgKF27DYWmabEjhEp+s3ymxQ@mail.gmail.com
Whole thread Raw
In response to Re: invalid data in file backup_label problem on windows  (Michael Paquier <michael@paquier.xyz>)
Responses Re: invalid data in file backup_label problem on windows  (David Steele <david@pgmasters.net>)
List pgsql-hackers
On Mon, Mar 29, 2021 at 7:01 AM Michael Paquier <michael@paquier.xyz> wrote:
>
> On Sun, Mar 28, 2021 at 09:29:10AM -0400, Andrew Dunstan wrote:
> > -     vital to the backup working, and must be written without modification.
> > +     vital to the backup working and must be written without
> > modification, which
> > +     may include opening the file in binary mode.
>
> += "on Windows"?

I'd say no, better to just tell people to always open the file in
binary mode. It's not hurtful anywhere, there's really no reason ever
to open it in text mode. And if we clearly tell everybody to open it
in binary mode, that lowers the bar in the unlikely event that we
might want to store some other non-text data in it in the future.

-- 
 Magnus Hagander
 Me: https://www.hagander.net/
 Work: https://www.redpill-linpro.com/



pgsql-hackers by date:

Previous
From: Andrey Borodin
Date:
Subject: Re: MultiXact\SLRU buffers configuration
Next
From: Pavel Stehule
Date:
Subject: Re: [Proposal] Global temporary tables