ICU-5194 fallback to "root" instead of ""

X-SVN-Rev: 19623
This commit is contained in:
Doug Felt 2006-05-10 23:28:25 +00:00
parent 5b973ae614
commit 591f3b0253

View file

@ -749,6 +749,9 @@ public final class ULocale implements Serializable {
if (loc == null) {
return null;
}
if (loc.toString().length() == 0) {
return ROOT;
}
ULocale result = (ULocale)CACHE.get(loc);
if (result == null && defaultULocale != null && loc == defaultULocale.locale) {
result = defaultULocale;