Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
dnzbk committed Apr 10, 2024
1 parent 42e5579 commit 524552b
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions daemon/postprocess/Unpack.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
* This file is part of nzbget. See <https://nzbget.com>.
*
* Copyright (C) 2013-2018 Andrey Prygunkov <[email protected]>
* Copyright (C) 2024 Denis <[email protected]>
* Copyright (C) 2023-2024 Denis <[email protected]>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
Expand Down Expand Up @@ -724,10 +724,6 @@ bool UnpackController::Cleanup()
// silently overwrite existing files
FileSystem::DeleteFile(dstFile);

#ifndef WIN32
FileSystem::SetFilePermissionsWithUmask(dstFile.Str(), g_Options->GetUMask());
#endif

bool hiddenFile = filename[0] == '.';

if (!FileSystem::MoveFile(srcFile, dstFile) && !hiddenFile)
Expand All @@ -737,6 +733,10 @@ bool UnpackController::Cleanup()
ok = false;
}

#ifndef WIN32
FileSystem::SetFilePermissionsWithUmask(dstFile.Str(), g_Options->GetUMask());
#endif

extractedFiles.push_back(filename);
}
}
Expand Down

0 comments on commit 524552b

Please sign in to comment.