Changeset 242204 in webkit


Ignore:
Timestamp:
Feb 28, 2019 10:22:34 AM (5 years ago)
Author:
mmaxfield@apple.com
Message:

Locale names can be nullptr
https://bugs.webkit.org/show_bug.cgi?id=195171
<rdar://problem/48262376>

Reviewed by Dean Jackson.

Nullptr can't be used in keys to HashMaps, so take an early out in this case.

This is a partial revert of r241288.

  • platform/graphics/cocoa/FontDescriptionCocoa.cpp:

(WebCore::FontDescription::platformResolveGenericFamily):

Location:
trunk/Source/WebCore
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r242196 r242204  
     12019-02-28  Myles C. Maxfield  <mmaxfield@apple.com>
     2
     3        Locale names can be nullptr
     4        https://bugs.webkit.org/show_bug.cgi?id=195171
     5        <rdar://problem/48262376>
     6
     7        Reviewed by Dean Jackson.
     8
     9        Nullptr can't be used in keys to HashMaps, so take an early out in this case.
     10
     11        This is a partial revert of r241288.
     12
     13        * platform/graphics/cocoa/FontDescriptionCocoa.cpp:
     14        (WebCore::FontDescription::platformResolveGenericFamily):
     15
    1162019-02-28  Justin Fan  <justin_fan@apple.com>
    217
  • trunk/Source/WebCore/platform/graphics/cocoa/FontDescriptionCocoa.cpp

    r241288 r242204  
    166166AtomicString FontDescription::platformResolveGenericFamily(UScriptCode script, const AtomicString& locale, const AtomicString& familyName)
    167167{
    168     if (script == USCRIPT_COMMON)
     168    if (locale.isNull() || script == USCRIPT_COMMON)
    169169        return nullAtom();
    170170
Note: See TracChangeset for help on using the changeset viewer.