aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEugene Sandulenko2008-04-07 20:38:52 +0000
committerEugene Sandulenko2008-04-07 20:38:52 +0000
commit04ff7cb1c1f15d9fd46691c10f50153aa4d721d9 (patch)
tree486c8a884920eb3691805a85a82151b6ed77a2b0
parent732774fd8de3cb6cebcd78730813d26e0330e66e (diff)
downloadscummvm-rg350-04ff7cb1c1f15d9fd46691c10f50153aa4d721d9.tar.gz
scummvm-rg350-04ff7cb1c1f15d9fd46691c10f50153aa4d721d9.tar.bz2
scummvm-rg350-04ff7cb1c1f15d9fd46691c10f50153aa4d721d9.zip
Fix a recent regression reported in bug #1937042: "FEEBLE: Capitalization
variations when searching for files" svn-id: r31445
-rw-r--r--common/file.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/common/file.cpp b/common/file.cpp
index 7fe2e1b655..4a7aed0e3d 100644
--- a/common/file.cpp
+++ b/common/file.cpp
@@ -172,7 +172,7 @@ static FILE *fopenNoCase(const String &filename, const String &directory, const
//
if (!file) {
fileBuf.toUppercase();
- pathBuf += fileBuf;
+ pathBuf = dirBuf + fileBuf;
file = fopen(pathBuf.c_str(), mode);
}
@@ -181,7 +181,7 @@ static FILE *fopenNoCase(const String &filename, const String &directory, const
//
if (!file) {
fileBuf.toLowercase();
- pathBuf += fileBuf;
+ pathBuf = dirBuf + fileBuf;
file = fopen(pathBuf.c_str(), mode);
}
@@ -191,7 +191,7 @@ static FILE *fopenNoCase(const String &filename, const String &directory, const
if (!file) {
fileBuf.toLowercase();
fileBuf.setChar(toupper(fileBuf[0]),0);
- pathBuf += fileBuf;
+ pathBuf = dirBuf + fileBuf;
file = fopen(pathBuf.c_str(), mode);
}