summaryrefslogtreecommitdiff
path: root/src/fs/paths.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/fs/paths.cpp')
-rw-r--r--src/fs/paths.cpp14
1 files changed, 14 insertions, 0 deletions
diff --git a/src/fs/paths.cpp b/src/fs/paths.cpp
index aa1c453b0..8a9969461 100644
--- a/src/fs/paths.cpp
+++ b/src/fs/paths.cpp
@@ -27,6 +27,7 @@
#include "fs/paths.h"
#include "fs/virtfs.h"
+#include "utils/checkutils.h"
#include "utils/stringutils.h"
#ifdef USE_X11
@@ -101,6 +102,19 @@ bool checkPath(const std::string &path)
&& path.find("\\..") == std::string::npos;
}
+void prepareFsPath(std::string &path)
+{
+ std::string path2 = path;
+ sanitizePath(path);
+// can be enabled for debugging
+// if (path != path2)
+// {
+// reportAlways("Path can be improved: '%s' -> '%s'",
+// path2.c_str(),
+// path0.c_str());
+// }
+}
+
std::string &fixDirSeparators(std::string &str)
{
if (dirSeparator[0] == '/')