зеркало из https://github.com/mozilla/pjs.git
Fixing bug 230849. Making LossyCopyUTF16toASCII() and CopyASCIItoUTF8() truncate the destination even when the source is null. r=jshin@mailaps.org, sr=peterv@propagandism.org
This commit is contained in:
Родитель
e841e0b70d
Коммит
ce13bac37f
|
@ -166,8 +166,8 @@ NS_COM
|
|||
void
|
||||
LossyCopyUTF16toASCII( const PRUnichar* aSource, nsACString& aDest )
|
||||
{
|
||||
aDest.Truncate();
|
||||
if (aSource) {
|
||||
aDest.Truncate();
|
||||
LossyAppendUTF16toASCII(nsDependentString(aSource), aDest);
|
||||
}
|
||||
}
|
||||
|
@ -176,8 +176,8 @@ NS_COM
|
|||
void
|
||||
CopyASCIItoUTF16( const char* aSource, nsAString& aDest )
|
||||
{
|
||||
aDest.Truncate();
|
||||
if (aSource) {
|
||||
aDest.Truncate();
|
||||
AppendASCIItoUTF16(nsDependentCString(aSource), aDest);
|
||||
}
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче