1
0
mirror of https://github.com/postgrespro/pg_probackup.git synced 2024-12-04 10:44:46 +02:00

PGPRO-1376: Do not call dir_is_empty() twice, because readdir() may bring different ordering

This commit is contained in:
Arthur Zakirov 2018-07-06 19:18:05 +03:00
parent be8f3be6cd
commit 1d5f54c5ee

View File

@ -581,14 +581,6 @@ restore_directories(const char *pg_data_dir, const char *backup_dir)
linked_path, dir_created, link_name);
}
/*
* This check was done in check_tablespace_mapping(). But do
* it again.
*/
if (!dir_is_empty(linked_path))
elog(ERROR, "restore tablespace destination is not empty: \"%s\"",
linked_path);
if (link_sep)
elog(LOG, "create directory \"%s\" and symbolic link \"%.*s\"",
linked_path,