The commit fixes problems not taking in account while working on the

issue with rsync returning non-zero status on vanishing files on commit
83e5f98171.

Alvaro Herrera gave me some tips which pointed me in the correct
direction.

This was reported by sungjae lee <sj860908@gmail.com>
This commit is contained in:
Martin
2016-05-06 17:34:46 -03:00
parent 274a30efa5
commit 10e47441a2

View File

@@ -1665,7 +1665,7 @@ do_standby_clone(void)
It's quite common for this to happen on the data directory, particularly
with long running rsync on a busy server.
*/
if (r != 0 && r != 24)
if (!WIFEXITED(r) && WEXITSTATUS(r) != 24)
{
log_warning(_("standby clone: failed copying master data directory '%s'\n"),
master_data_directory);
@@ -1751,7 +1751,7 @@ do_standby_clone(void)
It's quite common for this to happen on the data directory, particularly
with long running rsync on a busy server.
*/
if (r != 0 && r != 24)
if (!WIFEXITED(r) && WEXITSTATUS(r) != 24)
{
log_warning(_("standby clone: failed copying tablespace directory '%s'\n"),
tblspc_dir_src.data);