From 3a8c7888807e4483bbdb3edd81c9893f3e2f427d Mon Sep 17 00:00:00 2001 From: ShadowNinja Date: Fri, 5 Sep 2014 20:08:51 -0400 Subject: Add mod security Due to compatibility concerns, this is temporarily disabled. --- src/filesys.h | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) (limited to 'src/filesys.h') diff --git a/src/filesys.h b/src/filesys.h index 7560d3c15..19fcbb673 100644 --- a/src/filesys.h +++ b/src/filesys.h @@ -103,13 +103,17 @@ std::string RemoveLastPathComponent(const std::string &path, // this does not resolve symlinks and check for existence of directories. std::string RemoveRelativePathComponents(std::string path); -// Return the filename from a path or the entire path if no directory delimiter -// is found. +// Returns the absolute path for the passed path, with "." and ".." path +// components and symlinks removed. Returns "" on error. +std::string AbsolutePath(const std::string &path); + +// Returns the filename from a path or the entire path if no directory +// delimiter is found. const char *GetFilenameFromPath(const char *path); bool safeWriteToFile(const std::string &path, const std::string &content); -}//fs +} // namespace fs #endif -- cgit v1.2.3