From 21069ec1635bd24ab33805e033d28f2c0b2de482 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Sat, 20 Feb 2016 21:20:59 +0300 Subject: Add missing const in utils directory. --- src/utils/files.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/utils/files.cpp') diff --git a/src/utils/files.cpp b/src/utils/files.cpp index 6408a8061..ae56c70da 100644 --- a/src/utils/files.cpp +++ b/src/utils/files.cpp @@ -210,7 +210,7 @@ int Files::copyFile(const std::string &restrict srcName, void Files::getFiles(const std::string &path, StringVect &list) { - char **fonts = PhysFs::enumerateFiles(path.c_str()); + char **const fonts = PhysFs::enumerateFiles(path.c_str()); for (char *const *i = fonts; *i; i++) { if (!PhysFs::isDirectory((path + *i).c_str())) @@ -221,7 +221,7 @@ void Files::getFiles(const std::string &path, StringVect &list) void Files::getDirs(const std::string &path, StringVect &list) { - char **fonts = PhysFs::enumerateFiles(path.c_str()); + char **const fonts = PhysFs::enumerateFiles(path.c_str()); for (char *const *i = fonts; *i; i++) { if (PhysFs::isDirectory((path + *i).c_str())) @@ -232,7 +232,7 @@ void Files::getDirs(const std::string &path, StringVect &list) void Files::getFilesWithDir(const std::string &path, StringVect &list) { - char **fonts = PhysFs::enumerateFiles(path.c_str()); + char **const fonts = PhysFs::enumerateFiles(path.c_str()); for (char *const *i = fonts; *i; i++) { if (!PhysFs::isDirectory((path + *i).c_str())) @@ -353,7 +353,7 @@ void Files::saveTextFile(std::string path, void Files::deleteFilesInDirectory(std::string path) { path += "/"; - struct dirent *next_file = nullptr; + const struct dirent *next_file = nullptr; DIR *const dir = opendir(path.c_str()); while ((next_file = readdir(dir))) -- cgit v1.2.3-60-g2f50