From 930859d3a8dd343e8877f8c497e1fb351ca4f29b Mon Sep 17 00:00:00 2001 From: guccigang420 <> Date: Tue, 26 Sep 2023 00:08:10 +0200 Subject: [PATCH] Implemented missing functionality in GetInfo in filesystem_posix.cc --- src/xenia/base/filesystem_posix.cc | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/xenia/base/filesystem_posix.cc b/src/xenia/base/filesystem_posix.cc index 193e637eaa..932b8323f4 100644 --- a/src/xenia/base/filesystem_posix.cc +++ b/src/xenia/base/filesystem_posix.cc @@ -197,9 +197,13 @@ bool GetInfo(const std::filesystem::path& path, FileInfo* out_info) { if (stat(path.c_str(), &st) == 0) { if (S_ISDIR(st.st_mode)) { out_info->type = FileInfo::Type::kDirectory; + out_info->total_size = 0; } else { out_info->type = FileInfo::Type::kFile; + out_info->total_size = st.st_size; } + out_info->path = path.parent_path(); + out_info->name = path.filename(); out_info->create_timestamp = convertUnixtimeToWinFiletime(st.st_ctime); out_info->access_timestamp = convertUnixtimeToWinFiletime(st.st_atime); out_info->write_timestamp = convertUnixtimeToWinFiletime(st.st_mtime);