⚠ Archived content — this site is no longer maintained.   Current WebKit documentation is at docs.webkit.org.

Changeset 167524 in webkit


Ignore:
Timestamp:
Apr 18, 2014, 5:49:07 PM (12 years ago)
Author:
jhoneycutt@apple.com
Message:

Harden RenderInline::inlineElementContinuation()

<https://bugs.webkit.org/show_bug.cgi?id=131858>

Reviewed by Sam Weinig.

No new tests, as there are no known cases of this happening.

  • rendering/RenderInline.cpp:

(WebCore::RenderInline::inlineElementContinuation):
Return nullptr if the continuation is neither a RenderInline nor a
RenderBlock.

Location:
trunk/Source/WebCore
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r167523 r167524  
     12014-04-18  Jon Honeycutt  <jhoneycutt@apple.com>
     2
     3        Harden RenderInline::inlineElementContinuation()
     4
     5        <https://bugs.webkit.org/show_bug.cgi?id=131858>
     6
     7        Reviewed by Sam Weinig.
     8
     9        No new tests, as there are no known cases of this happening.
     10
     11        * rendering/RenderInline.cpp:
     12        (WebCore::RenderInline::inlineElementContinuation):
     13        Return nullptr if the continuation is neither a RenderInline nor a
     14        RenderBlock.
     15
    1162014-04-18  Stephanie Lewis  <slewis@apple.com>
    217
  • trunk/Source/WebCore/rendering/RenderInline.cpp

    r167278 r167524  
    120120{
    121121    RenderBoxModelObject* continuation = this->continuation();
    122     if (!continuation || continuation->isRenderInline())
     122    if (!continuation)
     123        return nullptr;
     124
     125    if (continuation->isRenderInline())
    123126        return toRenderInline(continuation);
    124     return toRenderBlock(continuation)->inlineElementContinuation();
     127
     128    return continuation->isRenderBlock() ? toRenderBlock(continuation)->inlineElementContinuation() : nullptr;
    125129}
    126130
Note: See TracChangeset for help on using the changeset viewer.