Reviewed by me, fix by Kida-san.
authordarin <darin@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 28 Mar 2005 01:50:25 +0000 (01:50 +0000)
committerdarin <darin@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 28 Mar 2005 01:50:25 +0000 (01:50 +0000)
        - fixed <rdar://problem/4067474> 8A424: Safari immediately quit by Cmd+Ctrll+'D'

        * kwq/WebCoreBridge.mm: (-[WebCoreBridge convertToNSRange:DOM::]):
        Added nil check.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@8979 268f45cc-cd09-0410-ab3c-d52691b4dbfc

WebCore/ChangeLog-2005-08-23
WebCore/kwq/WebCoreBridge.mm

index 1937dc5e9512ecc088e698e17327ccbd088199b5..ed6218ac653cbd57c81beffdd481aa6d77cc3436 100644 (file)
@@ -1,3 +1,12 @@
+2005-03-27  Darin Adler  <darin@apple.com>
+
+        Reviewed by me, fix by Kida-san.
+
+        - fixed <rdar://problem/4067474> 8A424: Safari immediately quit by Cmd+Ctrll+'D'
+
+        * kwq/WebCoreBridge.mm: (-[WebCoreBridge convertToNSRange:DOM::]):
+        Added nil check.
+
 === Safari-412 ===
 
 2005-03-24  Richard Williamson   <rjw@apple.com>
index e3660865c78ab1fc950b86e793d93de692d3b935..4111cc2da66668cc354a1eb5a9c74410af9f2a9b 100644 (file)
@@ -1628,6 +1628,10 @@ static HTMLFormElementImpl *formElementFromDOMElement(DOMElement *element)
 
 - (NSRange)convertToNSRange:(DOM::RangeImpl *)drange
 {
+    if (!drange) {
+        return NSMakeRange(NSNotFound, 0);
+    }
+
     Range toStartRange, toEndRange;
     Range actualRange = Range(drange);
     long startPosition, endPosition;