]> granicus.if.org Git - postgresql/commit
pg_upgrade: Report full disk better
authorPeter Eisentraut <peter_e@gmx.net>
Tue, 19 Nov 2013 02:49:40 +0000 (21:49 -0500)
committerPeter Eisentraut <peter_e@gmx.net>
Tue, 19 Nov 2013 03:02:36 +0000 (22:02 -0500)
commit8ca75671bd583f2e814c865941da464d2419312c
treeb94fc44251b4231578c1e52c9effa34ba352076c
parentea2bb1b47d7629a17dbc0c7da66cf063f8d3a768
pg_upgrade: Report full disk better

Previously, pg_upgrade would abort copy_file() on a short write without
setting errno, which the caller would report as an error with the
message "Success".  We assume ENOSPC in that case, as we do elsewhere in
the code.  Also set errno in some other error cases in copy_file() to
avoid bogus "Success" error messages.

This was broken in 6b711cf37c228749b6a8cef50e16e3c587d18dd4, so 9.2 and
before are OK.
contrib/pg_upgrade/file.c