summaryrefslogtreecommitdiff
path: root/src/strings.cpp
diff options
context:
space:
mode:
authorDarkvater <darkvater@openttd.org>2007-02-20 00:09:23 +0000
committerDarkvater <darkvater@openttd.org>2007-02-20 00:09:23 +0000
commit92bbe45dd031c7a14b9ba55a77a27d66cf07b876 (patch)
tree2597b59d39104907743caf0340df546274f0b559 /src/strings.cpp
parent5b237758aaf4ba5d646ccfad2129312f30bfcfb2 (diff)
downloadopenttd-92bbe45dd031c7a14b9ba55a77a27d66cf07b876.tar.xz
(svn r8821) -Regression: Unable to browse directories on *nix if the filesystem is not in UTF-8 charset and special characters are used. The string passed to opendir() which is UTF-8 was not parsed back to the filesystem format. Use a wrapper called ttd_opendir() instead of redefining opendir itself.
Diffstat (limited to 'src/strings.cpp')
-rw-r--r--src/strings.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/strings.cpp b/src/strings.cpp
index d794e9c97..d1ab5df0c 100644
--- a/src/strings.cpp
+++ b/src/strings.cpp
@@ -1164,7 +1164,7 @@ static int GetLanguageList(char **languages, int max)
struct dirent *dirent;
int num = 0;
- dir = opendir(_paths.lang_dir);
+ dir = ttd_opendir(_paths.lang_dir);
if (dir != NULL) {
while ((dirent = readdir(dir)) != NULL) {
const char *d_name = FS2OTTD(dirent->d_name);