Fix a recent regression reported in bug #1937042: "FEEBLE: Capitalization

variations when searching for files"

svn-id: r31445
This commit is contained in:
Eugene Sandulenko 2008-04-07 20:38:52 +00:00
parent 732774fd8d
commit 04ff7cb1c1

View File

@ -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);
}