diff options
| -rw-r--r-- | zencore/blake3.cpp | 4 | ||||
| -rw-r--r-- | zencore/filesystem.cpp | 2 | ||||
| -rw-r--r-- | zencore/string.cpp | 2 |
3 files changed, 5 insertions, 3 deletions
diff --git a/zencore/blake3.cpp b/zencore/blake3.cpp index 663f21b6d..5869f19a3 100644 --- a/zencore/blake3.cpp +++ b/zencore/blake3.cpp @@ -8,7 +8,9 @@ #include <zencore/zencore.h> #include "../3rdparty/BLAKE3/c/blake3.h" -#pragma comment(lib, "blake3.lib") +#if ZEN_PLATFORM_WINDOWS +# pragma comment(lib, "blake3.lib") +#endif #include <string.h> diff --git a/zencore/filesystem.cpp b/zencore/filesystem.cpp index e42f94550..b5733c4ed 100644 --- a/zencore/filesystem.cpp +++ b/zencore/filesystem.cpp @@ -498,7 +498,7 @@ WriteFile(std::filesystem::path Path, const IoBuffer* const* Data, size_t Buffer ThrowSystemException(hRes, "File write failed for '{}'"_format(Path).c_str()); } #else - if (write(Fd, DataPtr, WriteSize) != WriteSize) + if (write(Fd, DataPtr, WriteSize) != int64_t(WriteSize)) { ThrowLastError("File write failed for '{}'"_format(Path)); } diff --git a/zencore/string.cpp b/zencore/string.cpp index 6dcdc9542..df387dc3c 100644 --- a/zencore/string.cpp +++ b/zencore/string.cpp @@ -76,7 +76,7 @@ FilepathFindExtension(const std::string_view& Path, const char* ExtensionToMatch // Look for extension introducer ('.') - for (size_t i = PathLen - 1; i >= 0; --i) + for (ssize_t i = PathLen - 1; i >= 0; --i) { if (Path[i] == '.') return Path.data() + i; |