summaryrefslogtreecommitdiffstatshomepage
path: root/src/lib/formats/fsmgr.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib/formats/fsmgr.cpp')
-rw-r--r--src/lib/formats/fsmgr.cpp9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/lib/formats/fsmgr.cpp b/src/lib/formats/fsmgr.cpp
index 09234ebcaf4..cc18a942ed5 100644
--- a/src/lib/formats/fsmgr.cpp
+++ b/src/lib/formats/fsmgr.cpp
@@ -369,6 +369,14 @@ uint32_t filesystem_t::r32l(const uint8_t *p)
return p[0] | (p[1] << 8) | (p[2] << 16) | (p[3] << 24);
}
+std::string filesystem_t::trim_end_spaces(const std::string &str)
+{
+ auto i = str.end();
+ while(i != str.begin() && i[-1] == ' ')
+ i--;
+ return std::string(str.begin(), i);
+}
+
filesystem_t::file_t filesystem_t::idir_t::file_create(const fs_meta_data &info)
{
fatalerror("file_create called on a filesystem not supporting write\n");
@@ -413,6 +421,7 @@ std::vector<u8> filesystem_t::ifile_t::rsrc_read_all()
const char *fs_meta_data::entry_name(fs_meta_name name)
{
switch(name) {
+ case fs_meta_name::basic: return "basic";
case fs_meta_name::creation_date: return "creation_date";
case fs_meta_name::length: return "length";
case fs_meta_name::loading_address: return "loading_address";