Bug 491193 - fix intl warnings. r=smontagu
This commit is contained in:
Родитель
01dbd43a3e
Коммит
69843112f0
|
@ -101,7 +101,7 @@ nsConverterOutputStream::Write(PRUint32 aCount, const PRUnichar* aChars,
|
|||
|
||||
nsCAutoString buf;
|
||||
buf.SetLength(maxLen);
|
||||
if (buf.Length() != maxLen)
|
||||
if (buf.Length() != (PRUint32) maxLen)
|
||||
return NS_ERROR_OUT_OF_MEMORY;
|
||||
|
||||
PRInt32 outLen = maxLen;
|
||||
|
@ -112,7 +112,7 @@ nsConverterOutputStream::Write(PRUint32 aCount, const PRUnichar* aChars,
|
|||
// Yes, NS_ERROR_UENC_NOMAPPING is a success code
|
||||
return NS_ERROR_LOSS_OF_SIGNIFICANT_DATA;
|
||||
}
|
||||
NS_ASSERTION(inLen == aCount,
|
||||
NS_ASSERTION((PRUint32) inLen == aCount,
|
||||
"Converter didn't consume all the data!");
|
||||
|
||||
PRUint32 written;
|
||||
|
|
|
@ -587,6 +587,10 @@ NS_IMETHODIMP nsISO2022CNToUnicode::Convert(const char * aSrc, PRInt32 * aSrcLen
|
|||
}
|
||||
break;
|
||||
|
||||
case eState_ERROR:
|
||||
NS_NOTREACHED("unhandled case");
|
||||
goto error2;
|
||||
|
||||
} // switch
|
||||
src++;
|
||||
}
|
||||
|
|
|
@ -662,8 +662,8 @@ nsCharType GetCharType(PRUint32 aChar)
|
|||
nsCharType oResult;
|
||||
eBidiCategory bCat = GetBidiCat(aChar);
|
||||
if (eBidiCat_CC != bCat) {
|
||||
NS_ASSERTION(bCat < (sizeof(ebc2ucd)/sizeof(nsCharType)), "size mismatch");
|
||||
if(bCat < (sizeof(ebc2ucd)/sizeof(nsCharType)))
|
||||
NS_ASSERTION((PRUint32) bCat < (sizeof(ebc2ucd)/sizeof(nsCharType)), "size mismatch");
|
||||
if((PRUint32) bCat < (sizeof(ebc2ucd)/sizeof(nsCharType)))
|
||||
oResult = ebc2ucd[bCat];
|
||||
else
|
||||
oResult = ebc2ucd[0]; // something is very wrong, but we need to return a value
|
||||
|
|
Загрузка…
Ссылка в новой задаче