Bug 141433

Summary: ASSERTION FAILED: !beforeChild->isRubyRun() in WebCore::RenderRubyAsBlock::addChild
Product: WebKit Reporter: Renata Hodovan <rhodovan.u-szeged>
Component: Layout and RenderingAssignee: zalan <zalan>
Status: RESOLVED FIXED    
Severity: Normal CC: bfulgham, commit-queue, esprehn+autocc, glenn, koivisto, kondapallykalyan, mihnea, sam, webkit-bug-importer, zalan
Priority: P2 Keywords: InRadar
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   
Bug Depends on:    
Bug Blocks: 116980    
Attachments:
Description Flags
Test case
none
Test reduction
none
Patch none

Description Renata Hodovan 2015-02-10 08:42:48 PST
Created attachment 246327 [details]
Test case

Load this with debug WK:

<!DOCTYPE html>
<style>
rt {
    display: list-item
}
ruby, script {
    display: block;
}
</style>
<rt>
    <ruby>
        <script></script>
    </ruby>
</rt>


Backtrace:

ASSERTION FAILED: !beforeChild->isRubyRun()
../../Source/WebCore/rendering/RenderRuby.cpp(285) : virtual void WebCore::RenderRubyAsBlock::addChild(WebCore::RenderObject*, WebCore::RenderObject*)

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 0x7fff8affd700 (LWP 17689)]
0x00007fffed73b5ef in WTFCrash () at ../../Source/WTF/wtf/Assertions.cpp:321
321	    *(int *)(uintptr_t)0xbbadbeef = 0;
#0  0x00007fffed73b5ef in WTFCrash () at ../../Source/WTF/wtf/Assertions.cpp:321
#1  0x00007ffff396b3aa in WebCore::RenderRubyAsBlock::addChild (this=0x7ffff7f136c0, child=0x7fff984dcd10, beforeChild=0x7ffff7f13600) at ../../Source/WebCore/rendering/RenderRuby.cpp:285
#2  0x00007ffff39281c0 in WebCore::RenderListItem::insertOrMoveMarkerRendererIfNeeded (this=0x7ffff7f19750) at ../../Source/WebCore/rendering/RenderListItem.cpp:293
#3  0x00007ffff39282bd in WebCore::RenderListItem::layout (this=0x7ffff7f19750) at ../../Source/WebCore/rendering/RenderListItem.cpp:307
#4  0x00007ffff37ee9a0 in WebCore::RenderBlockFlow::layoutBlockChild (this=0x7ffff7f139c0, child=..., marginInfo=..., previousFloatLogicalBottom=..., maxFloatLogicalBottom=...) at ../../Source/WebCore/rendering/RenderBlockFlow.cpp:703
#5  0x00007ffff37ee4e7 in WebCore::RenderBlockFlow::layoutBlockChildren (this=0x7ffff7f139c0, relayoutChildren=true, maxFloatLogicalBottom=...) at ../../Source/WebCore/rendering/RenderBlockFlow.cpp:626
#6  0x00007ffff37ed914 in WebCore::RenderBlockFlow::layoutBlock (this=0x7ffff7f139c0, relayoutChildren=true, pageLogicalHeight=...) at ../../Source/WebCore/rendering/RenderBlockFlow.cpp:479
#7  0x00007ffff37c347f in WebCore::RenderBlock::layout (this=0x7ffff7f139c0) at ../../Source/WebCore/rendering/RenderBlock.cpp:927
#8  0x00007ffff37ee9a0 in WebCore::RenderBlockFlow::layoutBlockChild (this=0x7ffff7f13c00, child=..., marginInfo=..., previousFloatLogicalBottom=..., maxFloatLogicalBottom=...) at ../../Source/WebCore/rendering/RenderBlockFlow.cpp:703
#9  0x00007ffff37ee4e7 in WebCore::RenderBlockFlow::layoutBlockChildren (this=0x7ffff7f13c00, relayoutChildren=true, maxFloatLogicalBottom=...) at ../../Source/WebCore/rendering/RenderBlockFlow.cpp:626
#10 0x00007ffff37ed914 in WebCore::RenderBlockFlow::layoutBlock (this=0x7ffff7f13c00, relayoutChildren=true, pageLogicalHeight=...) at ../../Source/WebCore/rendering/RenderBlockFlow.cpp:479
#11 0x00007ffff37c347f in WebCore::RenderBlock::layout (this=0x7ffff7f13c00) at ../../Source/WebCore/rendering/RenderBlock.cpp:927
#12 0x00007ffff37ee9a0 in WebCore::RenderBlockFlow::layoutBlockChild (this=0x7ffff7f18b40, child=..., marginInfo=..., previousFloatLogicalBottom=..., maxFloatLogicalBottom=...) at ../../Source/WebCore/rendering/RenderBlockFlow.cpp:703
#13 0x00007ffff37ee4e7 in WebCore::RenderBlockFlow::layoutBlockChildren (this=0x7ffff7f18b40, relayoutChildren=true, maxFloatLogicalBottom=...) at ../../Source/WebCore/rendering/RenderBlockFlow.cpp:626
#14 0x00007ffff37ed914 in WebCore::RenderBlockFlow::layoutBlock (this=0x7ffff7f18b40, relayoutChildren=true, pageLogicalHeight=...) at ../../Source/WebCore/rendering/RenderBlockFlow.cpp:479
#15 0x00007ffff37c347f in WebCore::RenderBlock::layout (this=0x7ffff7f18b40) at ../../Source/WebCore/rendering/RenderBlock.cpp:927
#16 0x00007ffff39c2a39 in WebCore::RenderView::layoutContent (this=0x7ffff7f18b40, state=...) at ../../Source/WebCore/rendering/RenderView.cpp:232
#17 0x00007ffff39c3109 in WebCore::RenderView::layout (this=0x7ffff7f18b40) at ../../Source/WebCore/rendering/RenderView.cpp:357
#18 0x00007ffff3526fa0 in WebCore::FrameView::layout (this=0x7ffff7ec5b00, allowSubtree=true) at ../../Source/WebCore/page/FrameView.cpp:1317
#19 0x00007ffff2ec8fa5 in WebCore::Document::implicitClose (this=0x7ffff7e8e000) at ../../Source/WebCore/dom/Document.cpp:2497
#20 0x00007ffff33cba05 in WebCore::FrameLoader::checkCallImplicitClose (this=0x7ffff7f38a98) at ../../Source/WebCore/loader/FrameLoader.cpp:901
#21 0x00007ffff33cb771 in WebCore::FrameLoader::checkCompleted (this=0x7ffff7f38a98) at ../../Source/WebCore/loader/FrameLoader.cpp:847
#22 0x00007ffff33cb4da in WebCore::FrameLoader::finishedParsing (this=0x7ffff7f38a98) at ../../Source/WebCore/loader/FrameLoader.cpp:767
#23 0x00007ffff2ed1e5a in WebCore::Document::finishedParsing (this=0x7ffff7e8e000) at ../../Source/WebCore/dom/Document.cpp:4629
#24 0x00007ffff3243961 in WebCore::HTMLConstructionSite::finishedParsing (this=0x7ffff7f32800) at ../../Source/WebCore/html/parser/HTMLConstructionSite.cpp:404
#25 0x00007ffff328047a in WebCore::HTMLTreeBuilder::finished (this=0x7ffff7f327e0) at ../../Source/WebCore/html/parser/HTMLTreeBuilder.cpp:2940
#26 0x00007ffff324c2fc in WebCore::HTMLDocumentParser::end (this=0x7ffff7ecd100) at ../../Source/WebCore/html/parser/HTMLDocumentParser.cpp:402
#27 0x00007ffff324c3ca in WebCore::HTMLDocumentParser::attemptToRunDeferredScriptsAndEnd (this=0x7ffff7ecd100) at ../../Source/WebCore/html/parser/HTMLDocumentParser.cpp:411
#28 0x00007ffff324b07a in WebCore::HTMLDocumentParser::prepareToStopParsing (this=0x7ffff7ecd100) at ../../Source/WebCore/html/parser/HTMLDocumentParser.cpp:132
#29 0x00007ffff324c401 in WebCore::HTMLDocumentParser::attemptToEnd (this=0x7ffff7ecd100) at ../../Source/WebCore/html/parser/HTMLDocumentParser.cpp:423
#30 0x00007ffff324c4af in WebCore::HTMLDocumentParser::finish (this=0x7ffff7ecd100) at ../../Source/WebCore/html/parser/HTMLDocumentParser.cpp:451
#31 0x00007ffff33bbb29 in WebCore::DocumentWriter::end (this=0x7ffff7eb8aa0) at ../../Source/WebCore/loader/DocumentWriter.cpp:247
#32 0x00007ffff33a70f9 in WebCore::DocumentLoader::finishedLoading (this=0x7ffff7eb8a00, finishTime=0) at ../../Source/WebCore/loader/DocumentLoader.cpp:440
#33 0x00007ffff33a6e62 in WebCore::DocumentLoader::notifyFinished (this=0x7ffff7eb8a00, resource=0x7ffff7ec5680) at ../../Source/WebCore/loader/DocumentLoader.cpp:374
#34 0x00007ffff345b7e8 in WebCore::CachedResource::checkNotify (this=0x7ffff7ec5680) at ../../Source/WebCore/loader/cache/CachedResource.cpp:293
#35 0x00007ffff345b8e6 in WebCore::CachedResource::finishLoading (this=0x7ffff7ec5680) at ../../Source/WebCore/loader/cache/CachedResource.cpp:309
#36 0x00007ffff3457f1f in WebCore::CachedRawResource::finishLoading (this=0x7ffff7ec5680, data=0x7ffff7e86570) at ../../Source/WebCore/loader/cache/CachedRawResource.cpp:104
#37 0x00007ffff340a3f1 in WebCore::SubresourceLoader::didFinishLoading (this=0x7ffff7ec5200, finishTime=0) at ../../Source/WebCore/loader/SubresourceLoader.cpp:364
#38 0x00007ffff3405d2b in WebCore::ResourceLoader::didFinishLoading (this=0x7ffff7ec5200, finishTime=0) at ../../Source/WebCore/loader/ResourceLoader.cpp:542
#39 0x00007ffff3db92b5 in WebCore::readCallback (asyncResult=0x6b91a0, data=0x7ffff7e7bb40) at ../../Source/WebCore/platform/network/soup/ResourceHandleSoup.cpp:1295
#40 0x00007fffeb2777e6 in async_ready_callback_wrapper (source_object=0x7c72d0, res=0x6b91a0, user_data=user_data@entry=0x7ffff7e7bb40) at ginputstream.c:523
#41 0x00007fffeb29d0e5 in g_task_return_now (task=0x6b91a0) at gtask.c:1077
#42 0x00007fffeb29d109 in complete_in_idle_cb (task=0x6b91a0) at gtask.c:1086
#43 0x00007fffea555a1d in g_main_dispatch (context=0x478b00) at gmain.c:3064
#44 g_main_context_dispatch (context=context@entry=0x478b00) at gmain.c:3663
#45 0x00007fffea555d88 in g_main_context_iterate (context=0x478b00, block=block@entry=1, dispatch=dispatch@entry=1, self=<optimized out>) at gmain.c:3734
#46 0x00007fffea55604a in g_main_loop_run (loop=0x901bd0) at gmain.c:3928
#47 0x00007ffff44b31e6 in WTF::RunLoop::run () at ../../Source/WTF/wtf/gtk/RunLoopGtk.cpp:59
#48 0x00007ffff29a1cfc in WebKit::ChildProcessMain<WebKit::WebProcess, WebKit::WebProcessMain> (argc=2, argv=0x7fffffffd938) at ../../Source/WebKit2/Shared/unix/ChildProcessMain.h:61
#49 0x00007ffff29a1b61 in WebKit::WebProcessMainUnix (argc=2, argv=0x7fffffffd938) at ../../Source/WebKit2/WebProcess/gtk/WebProcessMainGtk.cpp:77
#50 0x00000000004008d1 in main (argc=2, argv=0x7fffffffd938) at ../../Source/WebKit2/WebProcess/EntryPoint/unix/WebProcessMain.cpp:44
Comment 1 Brent Fulgham 2016-08-04 16:30:35 PDT
This reproduces in r204037.
Comment 2 Brent Fulgham 2016-08-04 17:58:20 PDT
<rdar://problem/27711351>
Comment 3 zalan 2016-12-09 08:32:04 PST
Created attachment 296652 [details]
Test reduction
Comment 4 zalan 2016-12-09 10:08:12 PST
Created attachment 296656 [details]
Patch
Comment 5 WebKit Commit Bot 2016-12-09 10:51:03 PST
Comment on attachment 296656 [details]
Patch

Clearing flags on attachment: 296656

Committed r209617: <http://trac.webkit.org/changeset/209617>
Comment 6 WebKit Commit Bot 2016-12-09 10:51:08 PST
All reviewed patches have been landed.  Closing bug.