diff options
author | Loic Blot <loic.blot@unix-experience.fr> | 2021-05-06 09:02:11 +0200 |
---|---|---|
committer | Loïc Blot <nerzhul@users.noreply.github.com> | 2021-05-06 16:01:52 +0200 |
commit | 225d4541ffb4d59001841747e0877a175da50c17 (patch) | |
tree | c6c7a0de449da5f9ab3390b16d0322e87a20ef82 /src/filesys.h | |
parent | ba40b3950057c54609f8e4a56139563d30f8b84f (diff) | |
download | minetest-225d4541ffb4d59001841747e0877a175da50c17.tar.gz minetest-225d4541ffb4d59001841747e0877a175da50c17.tar.bz2 minetest-225d4541ffb4d59001841747e0877a175da50c17.zip |
fix: extractZipFile is not part of Client but more generic.
This solve a crash from mainmenu while extracting the zip
Diffstat (limited to 'src/filesys.h')
-rw-r--r-- | src/filesys.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/filesys.h b/src/filesys.h index cfbfa02bf..a9584b036 100644 --- a/src/filesys.h +++ b/src/filesys.h @@ -36,6 +36,10 @@ with this program; if not, write to the Free Software Foundation, Inc., #define PATH_DELIM ":" #endif +namespace irr { namespace io { +class IFileSystem; +}} + namespace fs { @@ -125,6 +129,8 @@ const char *GetFilenameFromPath(const char *path); bool safeWriteToFile(const std::string &path, const std::string &content); +bool extractZipFile(irr::io::IFileSystem *fs, const char *filename, const std::string &destination); + bool ReadFile(const std::string &path, std::string &out); bool Rename(const std::string &from, const std::string &to); |