diff options
author | Andrei Karas <akaras@inbox.ru> | 2017-03-06 19:33:56 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2017-03-06 20:03:30 +0300 |
commit | 4194c632d90b144595422abe4aab308e7928511a (patch) | |
tree | 53cf82ea85075d08e77893711e907259950ec9eb | |
parent | 7c183b661c7ba59bcf489098462ab4373d126234 (diff) | |
download | mv-4194c632d90b144595422abe4aab308e7928511a.tar.gz mv-4194c632d90b144595422abe4aab308e7928511a.tar.bz2 mv-4194c632d90b144595422abe4aab308e7928511a.tar.xz mv-4194c632d90b144595422abe4aab308e7928511a.zip |
Add binary access mode in read zip archives.
By default windows using text mode for read/write files.
-rw-r--r-- | src/fs/virtfs/zip.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/fs/virtfs/zip.cpp b/src/fs/virtfs/zip.cpp index 3a4e349dc..8dd7d8080 100644 --- a/src/fs/virtfs/zip.cpp +++ b/src/fs/virtfs/zip.cpp @@ -61,7 +61,7 @@ namespace Zip std::vector<ZipLocalHeader*> &restrict headers = entry->mHeaders; std::vector<std::string> &restrict dirs = entry->mDirs; FILE *restrict const arcFile = fopen(archiveName.c_str(), - "r"); + "rb"); if (arcFile == nullptr) { reportAlways("Can't open zip file %s", @@ -216,7 +216,7 @@ namespace Zip } FILE *restrict const arcFile = fopen( header->zipEntry->root.c_str(), - "r"); + "rb"); if (arcFile == nullptr) { reportAlways("Can't open zip file %s", |