Re: Re: [COMMITTERS] pgsql: Map basebackup tablespaces using a tablespace_map file
От | Alvaro Herrera |
---|---|
Тема | Re: Re: [COMMITTERS] pgsql: Map basebackup tablespaces using a tablespace_map file |
Дата | |
Msg-id | 20150608174336.GM133018@postgresql.org обсуждение исходный текст |
Ответ на | Re: Re: [COMMITTERS] pgsql: Map basebackup tablespaces using a tablespace_map file (Robert Haas <robertmhaas@gmail.com>) |
Список | pgsql-hackers |
Robert Haas wrote: > Why not? I think that if we encounter some sort of situation that we > think should never happen, throwing an error is exactly what we > *should* do. Particularly when it comes to things like removing > files, it is very dangerous for the database to proceed if the > situation is not as expected. We should only remove things if we are > quite sure that removing them is the right thing to do. Yes, agreed. I notice that we use %m in places where I'm not sure errno is the right thing. Consider the ereport() at lines 10385ff, for instance. I don't think fgetc() nor ferror() set errno. I became aware of this because last week I was reading some bogus pg_dump code that reported "could not write foobar: Success" and noticed that the macros READ_ERROR_EXIT and WRITE_ERROR_EXIT also do strerror(errno) after doing some fread() or similar. -- Álvaro Herrera http://www.2ndQuadrant.com/ PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services
В списке pgsql-hackers по дате отправления: