diff options
author | Maxim Pimenov <m@maps.me> | 2017-09-18 14:17:10 +0300 |
---|---|---|
committer | Yuri Gorshenin <mipt.vi002@gmail.com> | 2017-09-25 15:21:27 +0300 |
commit | fd46f8ce23efd7e0a2107a8f2c1abc72b5bd01d5 (patch) | |
tree | e68a1e905ba975230fd882438f68836e6aaaa189 /platform/platform.hpp | |
parent | 343134145b8ec81f42da02beb03c867871495131 (diff) |
[platform] Acknowledge the MWM_WRITABLE_DIR env. variable on Linux.
Diffstat (limited to 'platform/platform.hpp')
-rw-r--r-- | platform/platform.hpp | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/platform/platform.hpp b/platform/platform.hpp index 86b9b1ecfa..dd0eb2bd3b 100644 --- a/platform/platform.hpp +++ b/platform/platform.hpp @@ -8,6 +8,7 @@ #include "coding/reader.hpp" #include "base/exception.hpp" +#include "base/macros.hpp" #include "base/task_loop.hpp" #include "base/worker_thread.hpp" @@ -126,8 +127,12 @@ public: /// Client app should not replace default resource dir. void SetResourceDir(string const & path); - /// Creates directory at filesystem - EError MkDir(string const & dirName) const; + /// Creates directory in the filesystem. + static EError MkDir(string const & dirName); + + /// Creates a directory. Returns true on success. + /// Returns false and logs the reason on failure. + WARN_UNUSED_RESULT static bool MkDirChecked(string const & dirName); /// Removes empty directory from the filesystem. static EError RmDir(string const & dirName); |