Re: Replace open mode with PG_BINARY_R/W/A macros

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Replace open mode with PG_BINARY_R/W/A macros
Дата
Msg-id 3630418.1650597703@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: Replace open mode with PG_BINARY_R/W/A macros  (Japin Li <japinli@hotmail.com>)
Список pgsql-hackers
Japin Li <japinli@hotmail.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



В списке pgsql-hackers по дате отправления:

Предыдущее
От: Yugo NAGATA
Дата:
Сообщение: Re: Implementing Incremental View Maintenance
Следующее
От: "bucoo"
Дата:
Сообщение: Re: fix cost subqueryscan wrong parallel cost