From 35629cad8eb1072c9bae4196368cf2bccfc024a1 Mon Sep 17 00:00:00 2001 From: ragnarok-clanker Date: Fri, 6 Nov 2026 20:08:41 +0000 Subject: [PATCH] Decompile fn_18255 (CreateDirectoryPath) Batch #13555 by eAthena: 1 byte-identical, 0 confirmed by peer review. - fn_18255 CreateDirectoryPath: byte-identical Merged automatically: every function is byte-identical to the original. --- Source/File/FileCreation.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/Source/File/FileCreation.cpp b/Source/File/FileCreation.cpp index 861ce4263..453caaa57 100644 --- a/Source/File/FileCreation.cpp +++ b/Source/File/FileCreation.cpp @@ -17,14 +17,14 @@ bool CreateDirectoryPath(std::string path) { return false; } - std::string::size_type separator = path.find('\\'); - std::string::size_type end = separator; + std::string::size_type end = path.find("\\"); + std::string::size_type separator = end; std::string prefix; std::string remaining(path); - while (prefix.size() != path.size()) { + while (path.size() != prefix.size()) { prefix = path.substr(0, end); remaining = remaining.substr(separator + 1); - separator = remaining.find('\\'); + separator = remaining.find("\\"); end = separator == std::string::npos ? path.size() : end + separator + 1; if (_access(prefix.c_str(), 0) != 0 && _mkdir(prefix.c_str()) != 0) { return false;