pg.ddx.io pgsql-bugs@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: Jorge Gustavo Rocha <jgr@geomaster.pt>
Cc: pgsql-bugs@lists.postgresql.org
Subject: Re: BUG #15827: Unable to connect on Windows using pg_services.conf using Python psycopg2
Date: Thu, 25 Jul 2019 12:13:32 -0400
Message-ID: <29487.1564071212@sss.pgh.pa.us> (raw )
In-Reply-To: <5805.1561750411@sss.pgh.pa.us >
References: <fcb5c34c-cf5f-6dc9-c68e-6b297f073b79@geomaster.pt >
<CA+mi_8aBnLKypX2Ttksg8JEhApBo=JpF6P_STQGp-FOvDpn6Yw@mail.gmail.com >
<81d9d421-6947-7111-a1dc-cfd99cd3ae53@geomaster.pt >
<23215.1560977098@sss.pgh.pa.us >
<20190620031218.GC2660@paquier.xyz >
<20190620070319.GH2660@paquier.xyz >
<0a9fcd30-5ae2-7e5f-ac1d-60d14a2ebb63@geomaster.pt >
<20190621004233.GA1626@paquier.xyz >
<3383.1561078113@sss.pgh.pa.us >
<25605.1561652435@sss.pgh.pa.us >
<20190628031056.GA1797@paquier.xyz >
<5805.1561750411@sss.pgh.pa.us >
I wrote:
> Michael Paquier <michael@paquier.xyz> writes:
>> I really think that
>> we should stick with the approach of only removing \r when it is
>> followed by \n as we basically want to be able to counter the text
>> mode of Windows when something external wrote files read by our code,
>> where \n has been magically transformed to \r\n.
> As I said, I'm not convinced that filtering \r only where it's actually
> adjacent to \n is sufficient, even on Windows. To suppose that it is
> sufficient, you'd have to assume that fgets() guarantees not to split
> the \r and \n across buffer boundaries, which I doubt that it does.
> (If it does do that, it would break some other assumptions we have about
> whether the buffer gets filled completely.)
Hearing nothing further on this, I went ahead with the patch as I had it
on HEAD, and a tweaked version of your patch on the back branches.
regards, tom lane
view thread (23+ messages) latest in thread
Message-ID: <29487.1564071212@sss.pgh.pa.us>
Permalink: ../29487.1564071212@sss.pgh.pa.us/
Also on: postgresql.org/message-id/29487.1564071212@sss.pgh.pa.us
copy link · copy postgr.es
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 using the --to and --cc options:
reply via email
To: pgsql-bugs@postgresql.org
Cc: tgl@sss.pgh.pa.us, michael@paquier.xyz, jgr@geomaster.pt, pgsql-bugs@lists.postgresql.org
Subject: Re: BUG #15827: Unable to connect on Windows using pg_services.conf using Python psycopg2
In-Reply-To: <29487.1564071212@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