LayoutTests:
authoradele <adele@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sat, 24 Mar 2007 04:05:04 +0000 (04:05 +0000)
committeradele <adele@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sat, 24 Mar 2007 04:05:04 +0000 (04:05 +0000)
        Reviewed by Adele.

        - test for http://bugs.webkit.org/show_bug.cgi?id=13124
          REGRESSION: Reproducible crash in Widget::getView

        * fast/frames/hover-timer-crash-expected.txt: Added.
        * fast/frames/hover-timer-crash.html: Added.

WebCore:

        Reviewed by Adele.

        - fix http://bugs.webkit.org/show_bug.cgi?id=13124
          REGRESSION: Reproducible crash in Widget::getView

        Test: fast/frames/hover-timer-crash.html

        * page/Frame.cpp:
        (WebCore::Frame::setView): Added a call to EventHandler::clear().

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

LayoutTests/ChangeLog
LayoutTests/fast/frames/hover-timer-crash-expected.txt [new file with mode: 0644]
LayoutTests/fast/frames/hover-timer-crash.html [new file with mode: 0644]
WebCore/ChangeLog
WebCore/page/Frame.cpp

index f03f18cb2136b1f5f638aa5d7d241fdb2ad30257..cd975d7e1ca690e2bd26e26bceca267b93a387a5 100644 (file)
@@ -1,3 +1,13 @@
+2007-03-23  Mitz Pettel  <mitz@webkit.org>
+
+        Reviewed by Adele.
+
+        - test for http://bugs.webkit.org/show_bug.cgi?id=13124
+          REGRESSION: Reproducible crash in Widget::getView
+
+        * fast/frames/hover-timer-crash-expected.txt: Added.
+        * fast/frames/hover-timer-crash.html: Added.
+
 2007-03-23  Justin Garcia  <justin.garcia@apple.com>
 
         Reviewed by adele
diff --git a/LayoutTests/fast/frames/hover-timer-crash-expected.txt b/LayoutTests/fast/frames/hover-timer-crash-expected.txt
new file mode 100644 (file)
index 0000000..4d05e33
--- /dev/null
@@ -0,0 +1,7 @@
+Test for http://bugs.webkit.org/show_bug.cgi?id=13124 REGRESSION: Reproducible crash in Widget::getView.
+
+To test interactively, move the mouse into the yellow rect and wait a second.
+
+No crash means SUCCESS.
+
+
diff --git a/LayoutTests/fast/frames/hover-timer-crash.html b/LayoutTests/fast/frames/hover-timer-crash.html
new file mode 100644 (file)
index 0000000..c4494ab
--- /dev/null
@@ -0,0 +1,43 @@
+<html>
+<head>
+    <script type="text/javascript">
+        function finish()
+        {
+            if (window.layoutTestController)
+                layoutTestController.notifyDone();
+        }
+
+        function crash_step2()
+        {
+          var target = document.getElementById("target");
+          target.contentDocument.body.parentNode.removeChild(target.contentDocument.body);
+          target.parentNode.removeChild(target);
+          setTimeout(finish, 10);
+        }
+
+        function test()
+        {
+            if (window.layoutTestController) {
+                layoutTestController.dumpAsText();
+                layoutTestController.waitUntilDone();
+                var target = document.getElementById("target");
+                eventSender.mouseMoveTo(target.offsetLeft + target.offsetWidth / 2, target.offsetTop + target.offsetHeight / 2);
+                setTimeout(crash_step2, 100);
+            }
+        }
+    </script>
+</head>
+<body onload="test()">
+    <p>
+        Test for <i><a href="http://bugs.webkit.org/show_bug.cgi?id=13124">http://bugs.webkit.org/show_bug.cgi?id=13124</a>
+        REGRESSION: Reproducible crash in Widget::getView</i>.
+    </p>
+    <p>
+        To test interactively, move the mouse into the yellow rect and wait a second.
+    </p>
+    <p>
+        No crash means SUCCESS.
+    </p>
+    <iframe onmouseover="if (!window.layoutTestController) setTimeout(crash_step2, 1000)" id="target" src="data:text/html,<body bgcolor='yellow'></body>" style="border: solid black"></iframe>
+</body>
+</html>
index cbf22c6999f48546765d32042fc908681a46f591..6bdd0df7f45ca4ed8a263473e9ed0a672ad6f25b 100644 (file)
@@ -1,3 +1,15 @@
+2007-03-23  Mitz Pettel  <mitz@webkit.org>
+
+        Reviewed by Adele.
+
+        - fix http://bugs.webkit.org/show_bug.cgi?id=13124
+          REGRESSION: Reproducible crash in Widget::getView
+
+        Test: fast/frames/hover-timer-crash.html
+
+        * page/Frame.cpp:
+        (WebCore::Frame::setView): Added a call to EventHandler::clear().
+
 2007-03-23  Justin Garcia  <justin.garcia@apple.com>
 
         Reviewed by adele
index 040153a86d934e1b479e8303f92a6f8ee7777e5b..c1adf4a7f2ec0f6365f8cbde0a62646b94f8ede2 100644 (file)
@@ -272,6 +272,7 @@ void Frame::setView(FrameView* view)
         if (d->m_view)
             d->m_view->unscheduleRelayout();
     }
+    eventHandler()->clear();
 
     d->m_view = view;