ICU-4189 Fix previous change for Solaris with Workshpo 4.2.

X-SVN-Rev: 17158
This commit is contained in:
George Rhoten 2005-01-25 22:38:48 +00:00
parent 50ec20ea0d
commit 89826972bd
2 changed files with 2 additions and 2 deletions

View file

@ -309,7 +309,7 @@ static UScriptCode scriptNameToCode(const UnicodeString& name) {
UBool isInvariant = uprv_isInvariantUString(name.getBuffer(), nameLen);
if (isInvariant) {
name.extract(0, nameLen, buf, sizeof(buf), US_INV);
name.extract(0, nameLen, buf, (int32_t)sizeof(buf), US_INV);
buf[127] = 0; // Make sure that we NULL terminate the string.
}
if (!isInvariant || uscript_getCode(buf, &code, 1, &ec) != 1 || U_FAILURE(ec))

View file

@ -790,7 +790,7 @@ UnicodeString& U_EXPORT2 Transliterator::getDisplayName(const UnicodeString& id,
uprv_strcpy(key, RB_SCRIPT_DISPLAY_NAME_PREFIX);
args[j].getString(s);
if (uprv_isInvariantUString(s.getBuffer(), s.length())) {
s.extract(0, sizeof(key)-length-1, key+length, sizeof(key)-length-1, US_INV);
s.extract(0, sizeof(key)-length-1, key+length, (int32_t)sizeof(key)-length-1, US_INV);
resString = bundle.getStringEx(key, status);