Fix off-by-one error in conversion pointers. Bug 801681, r=emk

This commit is contained in:
Simon Montagu 2012-10-18 16:35:04 +02:00
parent 4a09c33129
commit a28941fe63

View File

@ -142,10 +142,11 @@ NS_IMETHODIMP nsHZToUnicode::ConvertNoBuff(
// and ' ' even in GB mode.
if (srcByte > 0x20 || HZ_ENCODING_STATE == HZ_STATE_ASCII) {
*aDest++ = UCS2_NO_MAPPING;
iDestlen++;
}
aSrc--;
(*aSrcLength)--;
iDestlen++;
i--;
break;
}
} else if (HZ_ENCODING_STATE == HZ_STATE_GB) {