Small WebKit

Issue 433: Crash in DOMCore

Reported by Riccardo Mottola, Apr 4, 2013

Steps to reproduce the problem:
1. Load http://duckduckgo.com/goodies.html
2. search for the "permalink", like "translate into 
pig latin". Sometimes you ned to folloow a link twice
3. clink on "permalink"

Actual result: Crash with stacktrace:

#0  0xb6d7d95e in objc_msg_lookup ()
   from /usr/lib/gcc/i686-pc-linux-gnu/4.6.3/libobjc.so.3
#1  0xb6e3dd0e in -[GSInlineArray initWithObjects:count:] (
    self=<value optimized out>, _cmd=0xb71abd60, 
objects=0xbfbde630, count=1)
    at GSArray.m:361
#2  0xb6e3dc77 in -[GSPlaceholderArray initWithObjects:count:] (
    self=0x9a6063c, _cmd=0xb71d5c50, objects=0xbfbde630, count=1)
    at GSArray.m:361
#3  0xb6f061ff in -[NSDictionary allValues] (self=0xc4161ec, 
_cmd=0xb77453c8)
    at NSDictionary.m:789
#4  0xb76e9460 in -[DOMNamedNodeMap dealloc] (self=0x1800c9e4, 
_cmd=0xb71f3788)
    at DOMCore.m:161
#5  0xb6f6c425 in -[NSObject release] (self=0x1800c9e4, 
_cmd=0xb77452b0)
    at NSObject.m:1420
#6  0xb76e9546 in -[DOMElement dealloc] (self=0xaf0c744, 
_cmd=0xb71f3788)
    at DOMCore.m:161
#7  0xb6f6c425 in -[NSObject release] (self=0xaf0c744, 
_cmd=0xb71abc80)
    at NSObject.m:1420
#8  0xb6e3d0e3 in -[GSArray dealloc] (self=0xaa1f4b4, 
_cmd=0xb71f3788)
    at GSArray.m:361
#9  0xb6f6c425 in -[NSObject release] (self=0xaa1f4b4, 
_cmd=0xb77452b0)
    at NSObject.m:1420
#10 0xb76e92a3 in -[DOMNodeList dealloc] (self=0x14a691bc, 
_cmd=0xb71f3788)
---
#4  0xb76e9460 in -[DOMNamedNodeMap dealloc] (self=0x1800c9e4, 
_cmd=0xb71f3788)
    at DOMCore.m:161
161       return ((_childNodes != nil) && ([_childNodes 
length] > 0))?((DOMNode *)[_childNodes item:0]) : (DOMNode *)nil;

I'm unable to print _childNodes though.

Comment 1 by Riccardo Mottola, Apr 4, 2013

The fact that when you click on a link and it doesn't crash is 
related to 363
Relations: is related to 363

Comment 2 by Nikolaus Schaller, Apr 22, 2013

Can't test on Cocoa since the page appears to use many many style 
rules and fills the memory with autoreleased objects.

Maybe this is also the reason for the crash (weakly detected out of 
memory situation).

Solution: add ARPs for the rule match/apply process

Comment 3 by Nikolaus Schaller, Apr 22, 2013

Adding ARPs does not really help. So there appears to be some loop 
making the page grow and grow to GBytes in _layout / _spliceNode:

Comment 4 by Nikolaus Schaller, Apr 23, 2013

The memory allocation issue was triggered by running it with 
NSZombieEnabled.
But rendering is still very slow.
The resulting attributed string has approx. 65000 characters and 
attributes and the CSS database appears to be quite big. So 
searching the CSS styles for each element and splicing the 
attributed string should be made faster (caching?).
The page finally loads and displays something, but all the text is 
very small. So this might be parsing/processing errors in CSS 
resulting in very small fonts.
But it did not crash (on Cocoa).

Comment 5 by Paldweve Caldwellbe, Oct 12, 2019

Here is another issue infront of you. Crash in DOM core is here on 
this page for this page we are heaving something new which is just 
menmtion for getting interested work with the help of these 
https://www.researchwritingkings.com/review-of-essayschief-com/ 
sites. Hope you also make it more interested with some good work.

Created: 12 years 11 months ago by Riccardo Mottola

Updated: 6 years 5 months ago

Status: New

Followed by: 2 persons

Labels:
Type:Defect
Priority:Medium

This issue is related to
363 - sea... / parameters not passed