mirror of
https://github.com/storytold/harfbuzz.git
synced 2026-11-21 15:01:01 +01:00
[icu] Make sure we return script UNKNOWN instead of INVALID
This commit is contained in:
1 parent
d02985ec5a
commit
03034acb8a
1 file changed
+3
@@ -157,6 +157,9 @@ hb_icu_get_script (hb_unicode_funcs_t *ufuncs,
|
||||
UErrorCode status = U_ZERO_ERROR;
|
||||
UScriptCode scriptCode = uscript_getScript(unicode, &status);
|
||||
|
||||
if (unlikely (status != U_ZERO_ERROR))
|
||||
return HB_SCRIPT_UNKNOWN;
|
||||
|
||||
return hb_icu_script_to_script (scriptCode);
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user