Skip to content

Commit

Permalink
Merge pull request #527 from typpos/master
Browse files Browse the repository at this point in the history
(#526) Fix: CopyLimit overflows at 4GB.
  • Loading branch information
DavidXanatos committed Feb 4, 2021
2 parents 47bc96a + 01a58ee commit 47d11ca
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Sandboxie/core/dll/file_copy.c
Original file line number Diff line number Diff line change
Expand Up @@ -125,10 +125,10 @@ _FX ULONG File_MigrateFile_GetMode(const WCHAR* TruePath, ULONGLONG file_size)
return mode;

//
// if tere is no configuration for this file type/path decide based on the file size
// if there is no configuration for this file type/path, then decide based on the file size
//

if (File_CopyLimitKb == -1 || file_size < (File_CopyLimitKb * 1024))
if (File_CopyLimitKb == -1 || file_size < ((ULONGLONG)File_CopyLimitKb * 1024))
return FILE_COPY_CONTENT;

//
Expand Down

0 comments on commit 47d11ca

Please sign in to comment.