Title: [256008] trunk/Source/WebCore
- Revision
- 256008
- Author
- [email protected]
- Date
- 2020-02-06 21:19:16 -0800 (Thu, 06 Feb 2020)
Log Message
REGRESSION(r254534): 1-3% regression on PLT
https://bugs.webkit.org/show_bug.cgi?id=207244
Can't put null strings into hash maps.
Reviewed by Wenson Hsieh.
* platform/text/cocoa/LocaleCocoa.mm:
(WebCore::LocaleCocoa::canonicalLanguageIdentifierFromString):
Modified Paths
Diff
Modified: trunk/Source/WebCore/ChangeLog (256007 => 256008)
--- trunk/Source/WebCore/ChangeLog 2020-02-07 04:12:39 UTC (rev 256007)
+++ trunk/Source/WebCore/ChangeLog 2020-02-07 05:19:16 UTC (rev 256008)
@@ -1,5 +1,17 @@
2020-02-06 Myles C. Maxfield <[email protected]>
+ REGRESSION(r254534): 1-3% regression on PLT
+ https://bugs.webkit.org/show_bug.cgi?id=207244
+
+ Can't put null strings into hash maps.
+
+ Reviewed by Wenson Hsieh.
+
+ * platform/text/cocoa/LocaleCocoa.mm:
+ (WebCore::LocaleCocoa::canonicalLanguageIdentifierFromString):
+
+2020-02-06 Myles C. Maxfield <[email protected]>
+
[Cocoa] Rename LocaleMac to LocaleCocoa
https://bugs.webkit.org/show_bug.cgi?id=207371
Modified: trunk/Source/WebCore/platform/text/cocoa/LocaleCocoa.mm (256007 => 256008)
--- trunk/Source/WebCore/platform/text/cocoa/LocaleCocoa.mm 2020-02-07 04:12:39 UTC (rev 256007)
+++ trunk/Source/WebCore/platform/text/cocoa/LocaleCocoa.mm 2020-02-07 05:19:16 UTC (rev 256008)
@@ -288,6 +288,8 @@
AtomString LocaleCocoa::canonicalLanguageIdentifierFromString(const AtomString& string)
{
+ if (string.isEmpty())
+ return string;
return canonicalLocaleMap().ensure(string, [&] {
return [NSLocale canonicalLanguageIdentifierFromString:string];
}).iterator->value;
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes