Re: Tighten error control for OpenTransientFile/CloseTransientFile
Alvaro Herrera <alvherre@2ndquadrant.com>
From: Alvaro Herrera <alvherre@2ndquadrant.com>
To: Michael Paquier <michael@paquier.xyz>
Cc: Georgios Kokolatos <gkokolatos@pm.me>, pgsql-hackers@lists.postgresql.org
Date: 2019-03-08T01:00:05Z
Lists: pgsql-hackers
On 2019-Mar-07, Michael Paquier wrote:
> #else
> - close(fd);
> + if (close(fd))
> + {
> + fprintf(stderr, _("%s: could not close file \"%s\": %s"),
> + progname, ControlFilePath, strerror(errno));
> + exit(EXIT_FAILURE);
> + }
> #endif
I think this one needs a terminating \n.
--
Álvaro Herrera https://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services
Commits
-
Tighten use of OpenTransientFile and CloseTransientFile
- 82a5649fb9db 12.0 landed
-
PANIC on fsync() failure.
- 9ccdd7f66e33 12.0 cited