[7296] Fixed some GCC warnings.

This commit is contained in:
VladimirMangos 2009-02-18 19:15:53 +03:00
parent 0be9e35b7b
commit 6793f9256f
4 changed files with 8 additions and 10 deletions

View file

@ -252,8 +252,9 @@ bool Utf8toWStr(char const* utf8str, size_t csize, wchar_t* wstr, size_t& wsize)
size_t len = utf8::distance(utf8str,utf8str+csize);
if(len > wsize)
{
if(wsize > 0)
wstr[0] = L'\0';
wsize = 0;
wstr = L"";
return false;
}
@ -263,8 +264,9 @@ bool Utf8toWStr(char const* utf8str, size_t csize, wchar_t* wstr, size_t& wsize)
}
catch(std::exception)
{
if(wsize > 0)
wstr[0] = L'\0';
wsize = 0;
wstr = L"";
return false;
}