From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
---|---|
To: | Japin Li <japinli(at)hotmail(dot)com> |
Cc: | Peter Eisentraut <peter(dot)eisentraut(at)enterprisedb(dot)com>, "pgsql-hackers(at)lists(dot)postgresql(dot)org" <pgsql-hackers(at)lists(dot)postgresql(dot)org> |
Subject: | Re: Replace open mode with PG_BINARY_R/W/A macros |
Date: | 2022-04-22 03:21:43 |
Message-ID: | 3630418.1650597703@sss.pgh.pa.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Japin Li <japinli(at)hotmail(dot)com> writes:
> I think we should also consider the popen() (see: OpenPipeStream() function),
> on the Windows, it can use "b", however, for linux, it might be not right.
Oh, ugh ... POSIX says for popen():
The behavior of popen() is specified for values of mode of r and
w. Other modes such as rb and wb might be supported by specific
implementations, but these would not be portable features. Note
that historical implementations of popen() only check to see if
the first character of mode is r. Thus, a mode of robert the robot
would be treated as mode r, and a mode of anything else would be
treated as mode w.
Maybe it's best to leave well enough alone here.
regards, tom lane
From | Date | Subject | |
---|---|---|---|
Next Message | bucoo | 2022-04-22 03:35:43 | Re: fix cost subqueryscan wrong parallel cost |
Previous Message | Yugo NAGATA | 2022-04-22 02:29:39 | Re: Implementing Incremental View Maintenance |