--- old/src/macosx/classes/sun/util/locale/provider/HostLocaleProviderAdapterImpl.java Thu Apr 18 13:25:05 2013 +++ new/src/macosx/classes/sun/util/locale/provider/HostLocaleProviderAdapterImpl.java Thu Apr 18 13:25:04 2013 @@ -1,5 +1,5 @@ /* - * Copyright (c) 2012, Oracle and/or its affiliates. All rights reserved. + * Copyright (c) 2012, 2013, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it @@ -520,7 +520,15 @@ } private static boolean isSupportedCalendarLocale(Locale locale) { - Locale base = locale.stripExtensions(); + Locale base = locale; + + if (base.hasExtensions() || base.getVariant() != "") { + base = new Locale.Builder() + .setLocale(locale) + .clearExtensions() + .build(); + } + if (!supportedLocaleSet.contains(base)) { return false; } @@ -527,7 +535,7 @@ String requestedCalType = locale.getUnicodeLocaleType("ca"); String nativeCalType = - getCalendarID(locale.toLanguageTag()).replaceFirst("gregorian", "gregory"); + getCalendarID(base.toLanguageTag()).replaceFirst("gregorian", "gregory"); if (requestedCalType == null) { return Calendar.getAvailableCalendarTypes().contains(nativeCalType);