From 1ae9a03a55bd35dc6f636d13b4dc85fec94253c5 Mon Sep 17 00:00:00 2001 From: Donkey <15072483565@163.com> Date: Tue, 29 Oct 2019 09:09:56 +0800 Subject: [PATCH] Update ZLFile.cpp MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit the container.xml file cause unable to parse epub file epub文件结构导致无法解析问题 --- jni/NativeFormats/zlibrary/core/src/filesystem/ZLFile.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/jni/NativeFormats/zlibrary/core/src/filesystem/ZLFile.cpp b/jni/NativeFormats/zlibrary/core/src/filesystem/ZLFile.cpp index 6ea83b401..6dcb6cd55 100644 --- a/jni/NativeFormats/zlibrary/core/src/filesystem/ZLFile.cpp +++ b/jni/NativeFormats/zlibrary/core/src/filesystem/ZLFile.cpp @@ -37,6 +37,10 @@ ZLFile::ZLFile() : myMimeTypeIsUpToDate(true), myInfoIsFilled(true) { } ZLFile::ZLFile(const std::string &path, const std::string &mimeType) : myPath(path), myMimeType(mimeType), myMimeTypeIsUpToDate(!mimeType.empty()), myInfoIsFilled(false) { + std::string::size_type position = myPath.find(":./"); + if (position != myPath.npos){ + myPath.replace(position, 3, ":"); + } ZLFSManager::Instance().normalize(myPath); { std::size_t index = ZLFSManager::Instance().findLastFileNameDelimiter(myPath);