use portable unlink in delete_walfiles_in_tli()

This commit is contained in:
Grigory Smolkin
2019-12-29 02:11:10 +03:00
parent 68922f2151
commit b0efb76003
2 changed files with 2 additions and 1 deletions
+1 -1
View File
@@ -933,7 +933,7 @@ delete_walfiles_in_tli(XLogRecPtr keep_lsn, timelineInfo *tlinfo,
}
/* unlink segment */
rc = unlink(wal_file->file.path);
rc = fio_unlink(wal_file->file.path, FIO_BACKUP_HOST);
if (rc < 0)
{
/* Missing file is not considered as error condition */
+1
View File
@@ -816,6 +816,7 @@ int fio_unlink(char const* path, fio_location location)
IO_CHECK(fio_write_all(fio_stdout, &hdr, sizeof(hdr)), sizeof(hdr));
IO_CHECK(fio_write_all(fio_stdout, path, path_len), path_len);
// TODO: error is swallowed ?
return 0;
}
else