mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 04:58:13 +00:00
Utilities/tar: Ignore directory entry if it already exists
This commit is contained in:
parent
1ae76676a5
commit
c94574d313
1 changed files with 1 additions and 1 deletions
|
@ -102,7 +102,7 @@ int main(int argc, char** argv)
|
||||||
case Archive::TarFileType::Directory: {
|
case Archive::TarFileType::Directory: {
|
||||||
Core::File::ensure_parent_directories(absolute_path);
|
Core::File::ensure_parent_directories(absolute_path);
|
||||||
|
|
||||||
if (mkdir(absolute_path.characters(), header.mode())) {
|
if (mkdir(absolute_path.characters(), header.mode()) && errno != EEXIST) {
|
||||||
perror("mkdir");
|
perror("mkdir");
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue