Bug 100972

Summary: [Mac] Crash in Range::editingStartPosition
Product: WebKit Reporter: Ryosuke Niwa <rniwa>
Component: HTML EditingAssignee: Ryosuke Niwa <rniwa>
Status: RESOLVED FIXED    
Severity: Normal CC: adele, ap, darin, enrica, mifenton, webkit.review.bot
Priority: P2 Keywords: InRadar
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Fixes the bug none

Description Ryosuke Niwa 2012-11-01 11:17:05 PDT
http://trac.webkit.org/browser/trunk/Source/WebCore/editing/mac/EditorMac.mm#L165
165	    RefPtr<Range> range = m_frame->selection()->toNormalizedRange();
166	    if (Node* startNode = adjustedSelectionStartForStyleComputation(m_frame->selection()->selection()).deprecatedNode()) {
167	        Node* pastEnd = range->pastLastNode();

range could be null in the line 165, in which case, we blow up in the line 167. We've been getting crash reports in Safari.

<rdar://problem/10227183>
Comment 1 Ryosuke Niwa 2012-11-01 11:20:59 PDT
Created attachment 171898 [details]
Fixes the bug
Comment 2 WebKit Review Bot 2012-11-01 12:02:41 PDT
Comment on attachment 171898 [details]
Fixes the bug

Clearing flags on attachment: 171898

Committed r133207: <http://trac.webkit.org/changeset/133207>
Comment 3 WebKit Review Bot 2012-11-01 12:02:46 PDT
All reviewed patches have been landed.  Closing bug.