zzip: fix compilation on Windows
NarrowPath is needed. Signed-off-by: Rosen Penev <rosenp@gmail.com>
This commit is contained in:
parent
6a4dc281d1
commit
f68fab53a7
@ -12,6 +12,7 @@
|
|||||||
#include "input/InputStream.hxx"
|
#include "input/InputStream.hxx"
|
||||||
#include "lib/fmt/PathFormatter.hxx"
|
#include "lib/fmt/PathFormatter.hxx"
|
||||||
#include "lib/fmt/RuntimeError.hxx"
|
#include "lib/fmt/RuntimeError.hxx"
|
||||||
|
#include "fs/NarrowPath.hxx"
|
||||||
#include "fs/Path.hxx"
|
#include "fs/Path.hxx"
|
||||||
#include "lib/fmt/SystemError.hxx"
|
#include "lib/fmt/SystemError.hxx"
|
||||||
#include "util/UTF8.hxx"
|
#include "util/UTF8.hxx"
|
||||||
@ -24,7 +25,7 @@ struct ZzipDir {
|
|||||||
ZZIP_DIR *const dir;
|
ZZIP_DIR *const dir;
|
||||||
|
|
||||||
explicit ZzipDir(Path path)
|
explicit ZzipDir(Path path)
|
||||||
:dir(zzip_dir_open(path.c_str(), nullptr)) {
|
:dir(zzip_dir_open(NarrowPath(path), nullptr)) {
|
||||||
if (dir == nullptr)
|
if (dir == nullptr)
|
||||||
throw FmtRuntimeError("Failed to open ZIP file {}",
|
throw FmtRuntimeError("Failed to open ZIP file {}",
|
||||||
path);
|
path);
|
||||||
|
Loading…
Reference in New Issue
Block a user