2
3
mirror of https://foundry.openuru.org/gitblit/r/CWE-ou-minkata.git synced 2025-07-13 18:17:49 -04:00

String function fixes for mingw.

This commit is contained in:
Darryl Pogue
2011-08-06 14:35:44 -07:00
parent ea3fa47eca
commit ee23f01736
11 changed files with 15 additions and 11 deletions

View File

@ -133,7 +133,7 @@ hsBool hsFolderIterator::NextFileSuffix(const char suffix[])
{
while (this->NextFile())
{ const char* fileSuffix = ::strrchr(this->GetFileName(), '.');
if (fileSuffix != nil && ::_stricmp(fileSuffix, suffix) == 0)
if (fileSuffix != nil && stricmp(fileSuffix, suffix) == 0)
return true;
}
return false;

View File

@ -114,7 +114,7 @@ hsBool plEncryptedStream::Open(const wchar* name, const wchar* mode)
{
if (wcscmp(mode, L"rb") == 0)
{
fRef = _wfopen(name, mode);
fRef = hsWFopen(name, mode);
fPosition = 0;
if (!fRef)
@ -515,7 +515,7 @@ bool plEncryptedStream::IsEncryptedFile(const char* fileName)
bool plEncryptedStream::IsEncryptedFile(const wchar* fileName)
{
FILE* fp = _wfopen(fileName, L"rb");
FILE* fp = hsWFopen(fileName, L"rb");
if (!fp)
return false;

View File

@ -206,7 +206,7 @@ bool plFileUtils::FileMove(const wchar* existingFile, const wchar* newFile)
bool plFileUtils::FileExists(const wchar* file)
{
FILE* fp = _wfopen(file, L"rb");
FILE* fp = hsWFopen(file, L"rb");
bool retVal = (fp != nil);
if (fp)
fclose(fp);
@ -502,4 +502,4 @@ bool plFileUtils::GetSecureEncryptionKey(const wchar* filename, UInt32* key, uns
return false;
}
}
}