From 198b5dfd50a83cd3d1dc8d7e56533abf8c4e40de Mon Sep 17 00:00:00 2001 From: hej Date: Wed, 6 Sep 2017 14:01:47 +0800 Subject: [PATCH] fixed chinese path bug --- native/extensions/assets-manager/Manifest.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/native/extensions/assets-manager/Manifest.cpp b/native/extensions/assets-manager/Manifest.cpp index 3c8085639b..a72b24d5eb 100644 --- a/native/extensions/assets-manager/Manifest.cpp +++ b/native/extensions/assets-manager/Manifest.cpp @@ -610,7 +610,8 @@ void Manifest::saveToFile(const std::string &filepath) rapidjson::PrettyWriter writer(buffer); _json.Accept(writer); - std::ofstream output(filepath, std::ofstream::out); + std::ofstream output(FileUtils::getInstance()->getSuitableFOpen(filepath), std::ofstream::out); + if(!output.bad()) output << buffer.GetString() << std::endl; }