pgsql: initdb -S should now have an explicit check that $PGDATA is vali

Поиск
Список
Период
Сортировка
От Tom Lane
Тема pgsql: initdb -S should now have an explicit check that $PGDATA is vali
Дата
Msg-id E1YyRQm-0006FI-QS@gemulon.postgresql.org
обсуждение исходный текст
Список pgsql-committers
initdb -S should now have an explicit check that $PGDATA is valid.

The fsync code from the backend essentially assumes that somebody's already
validated PGDATA, at least to the extent of it being a readable directory.
That's safe enough for initdb's normal code path too, but "initdb -S"
doesn't have any other processing at all that touches the target directory.
To have reasonable error-case behavior, add a pg_check_dir call.
Per gripe from Peter E.

Branch
------
REL9_4_STABLE

Details
-------
http://git.postgresql.org/pg/commitdiff/99f50dd720de59872bd842be3ec8eecea2be4b92

Modified Files
--------------
src/bin/initdb/initdb.c |   11 ++++++++++-
1 file changed, 10 insertions(+), 1 deletion(-)


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

Предыдущее
От: Tom Lane
Дата:
Сообщение: pgsql: initdb -S should now have an explicit check that $PGDATA is vali
Следующее
От: Bruce Momjian
Дата:
Сообщение: pgsql: pg_upgrade: add missing period in C comment