diff options
author | 2021-05-26 15:19:45 +0200 | |
---|---|---|
committer | 2021-05-26 19:15:31 +0200 | |
commit | 9add8034d2b92fe8cd876ab16c63831ce460e7e2 (patch) | |
tree | 5012a1ec8f5df8389a99805d9443351cb9653141 /src/lib/formats/fsmgr.cpp | |
parent | ec2bec33c2e53dada0970411f3b897930516d284 (diff) |
vtech: Add floppy formats and fs
Diffstat (limited to 'src/lib/formats/fsmgr.cpp')
-rw-r--r-- | src/lib/formats/fsmgr.cpp | 9 |
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"; |