pgsql: Fix pg_ctl's readfile() to not go into infinite loop on an empty

Поиск
Список
Период
Сортировка
От tgl@postgresql.org (Tom Lane)
Тема pgsql: Fix pg_ctl's readfile() to not go into infinite loop on an empty
Дата
Msg-id 20090902024107.3CD3475331E@cvs.postgresql.org
обсуждение исходный текст
Список pgsql-committers
Log Message:
-----------
Fix pg_ctl's readfile() to not go into infinite loop on an empty file
(could happen if either postgresql.conf or postmaster.opts is empty).
It's been broken since the C version was written for 8.0, so patch
all the way back.

initdb's copy of the function is broken in the same way, but it's
less important there since the input files should never be empty.
Patch that in HEAD only, and also fix some cosmetic differences that
crept into that copy of the function.

Per report from Corry Haines and Jeff Davis.

Tags:
----
REL8_3_STABLE

Modified Files:
--------------
    pgsql/src/bin/pg_ctl:
        pg_ctl.c (r1.92.2.6 -> r1.92.2.7)
        (http://anoncvs.postgresql.org/cvsweb.cgi/pgsql/src/bin/pg_ctl/pg_ctl.c?r1=1.92.2.6&r2=1.92.2.7)

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

Предыдущее
От: tgl@postgresql.org (Tom Lane)
Дата:
Сообщение: pgsql: Fix pg_ctl's readfile() to not go into infinite loop on an empty
Следующее
От: tgl@postgresql.org (Tom Lane)
Дата:
Сообщение: pgsql: Fix pg_ctl's readfile() to not go into infinite loop on an empty