diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/Config.h | 4 | ||||
| -rw-r--r-- | src/client/Client.cpp | 3 |
2 files changed, 7 insertions, 0 deletions
diff --git a/src/Config.h b/src/Config.h index 44ca23f..4dbe929 100644 --- a/src/Config.h +++ b/src/Config.h @@ -11,8 +11,10 @@ #ifdef WIN #define PATH_SEP "\\" +#define PATH_SEP_CHAR '\\' #else #define PATH_SEP "/" +#define PATH_SEP_CHAR '/' #endif //VersionInfoStart @@ -91,6 +93,8 @@ #define STAMPS_DIR "stamps" +#define BRUSH_DIR "Brushes" + #define APPDATA_SUBDIR "\\HardWIRED" //Number of unique thumbnails to have in cache at one time diff --git a/src/client/Client.cpp b/src/client/Client.cpp index 99c6b5b..67a018b 100644 --- a/src/client/Client.cpp +++ b/src/client/Client.cpp @@ -367,6 +367,9 @@ std::vector<std::string> Client::DirectorySearch(std::string directory, std::str std::vector<std::string> Client::DirectorySearch(std::string directory, std::string search, std::vector<std::string> extensions) { //Get full file listing + //Normalise directory string, ensure / or \ is present + if(*directory.rbegin() != '/' && *directory.rbegin() != '\\') + directory += PATH_SEP; std::vector<std::string> directoryList; #if defined(WIN) && !defined(__GNUC__) //Windows |
