Merge pull request #3421 from citusdata/allow_noent_in_remove

Don't error for ENOENT in CitusRemoveDirectory.
pull/3419/head
Hadi Moshayedi 2020-01-23 10:16:26 -08:00 committed by GitHub
commit 65dfcaa54b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -783,7 +783,7 @@ CitusRemoveDirectory(StringInfo filename)
removed = unlink(filename->data);
}
if (removed != 0)
if (removed != 0 && errno != ENOENT)
{
ereport(ERROR, (errcode_for_file_access(),
errmsg("could not remove file \"%s\": %m", filename->data)));