Commit 1cbb97de authored by sullivan@apple.com's avatar sullivan@apple.com

2009-05-27 John Sullivan <sullivan@apple.com>

        fixed <rdar://problem/6925482> repro crash in WebCore::DragController::dragExited dropping 
        bookmarks (at least) over Top Sites (at least)

        Reviewed by Kevin Decker

        * page/DragController.cpp:
        (WebCore::DragController::dragExited):
        nil check m_documentUnderMouse and take the "local file" case if it's nil



git-svn-id: http://svn.webkit.org/repository/webkit/trunk@44189 268f45cc-cd09-0410-ab3c-d52691b4dbfc
parent a4c1cc2f
2009-05-27 John Sullivan <sullivan@apple.com>
fixed <rdar://problem/6925482> repro crash in WebCore::DragController::dragExited dropping
bookmarks (at least) over Top Sites (at least)
Reviewed by Kevin Decker
* page/DragController.cpp:
(WebCore::DragController::dragExited):
nil check m_documentUnderMouse and take the "local file" case if it's nil
2009-05-27 Fridrich Strba <fridrich.strba@bluewin.ch>
Reviewed by Gustavo Noronha.
......@@ -155,7 +155,7 @@ void DragController::dragExited(DragData* dragData)
Frame* mainFrame = m_page->mainFrame();
if (RefPtr<FrameView> v = mainFrame->view()) {
ClipboardAccessPolicy policy = m_documentUnderMouse->securityOrigin()->isLocal() ? ClipboardReadable : ClipboardTypesReadable;
ClipboardAccessPolicy policy = (!m_documentUnderMouse || m_documentUnderMouse->securityOrigin()->isLocal()) ? ClipboardReadable : ClipboardTypesReadable;
RefPtr<Clipboard> clipboard = dragData->createClipboard(policy);
clipboard->setSourceOperation(dragData->draggingSourceOperationMask());
mainFrame->eventHandler()->cancelDragAndDrop(createMouseEvent(dragData), clipboard.get());
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment