diff --git a/src/archive/plugins/Bzip2ArchivePlugin.cxx b/src/archive/plugins/Bzip2ArchivePlugin.cxx index cd35eac5b..3f18f6067 100644 --- a/src/archive/plugins/Bzip2ArchivePlugin.cxx +++ b/src/archive/plugins/Bzip2ArchivePlugin.cxx @@ -11,6 +11,7 @@ #include "../ArchiveVisitor.hxx" #include "input/InputStream.hxx" #include "input/LocalOpen.hxx" +#include "fs/NarrowPath.hxx" #include "fs/Path.hxx" #include @@ -24,7 +25,7 @@ class Bzip2ArchiveFile final : public ArchiveFile { public: Bzip2ArchiveFile(Path path, InputStreamPtr &&_is) - :name(path.GetBase().c_str()), + :name(NarrowPath(path.GetBase())), istream(std::move(_is)) { // remove .bz2 suffix const size_t len = name.length();