From 9097db7d0f6f7e9c18066c3c7043b86a14f551a0 Mon Sep 17 00:00:00 2001 From: Jan Date: Thu, 2 Jan 2025 22:15:11 +0100 Subject: [PATCH] fix: compilation on windows --- src/ObjCompiling/Iwd/IwdCreator.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/ObjCompiling/Iwd/IwdCreator.cpp b/src/ObjCompiling/Iwd/IwdCreator.cpp index 833e7dfe..f995c32b 100644 --- a/src/ObjCompiling/Iwd/IwdCreator.cpp +++ b/src/ObjCompiling/Iwd/IwdCreator.cpp @@ -30,7 +30,7 @@ void IwdToCreate::Build(ISearchPath& searchPath, const std::filesystem::path& ou auto functions = FileToZlibWrapper::CreateFunctions32ForFile(&file); - auto zipFile = zipOpen2(filePath.c_str(), APPEND_STATUS_CREATE, nullptr, &functions); + auto zipFile = zipOpen2(filePath.string().c_str(), APPEND_STATUS_CREATE, nullptr, &functions); if (!zipFile) { std::cerr << std::format("Failed to open file as zip for iwd {}\n", m_name); @@ -68,7 +68,7 @@ void IwdToCreate::Build(ISearchPath& searchPath, const std::filesystem::path& ou readFile.m_stream->read(tempBuffer, sizeof(tempBuffer)); const auto readCount = readFile.m_stream->gcount(); if (readCount > 0) - zipWriteInFileInZip(zipFile, tempBuffer, readCount); + zipWriteInFileInZip(zipFile, tempBuffer, static_cast(readCount)); } while (!readFile.m_stream->eof()); zipCloseFileInZip(zipFile);