Commit 5b549d6e authored by darin@apple.com's avatar darin@apple.com

2009-04-26 Darin Adler <darin@apple.com>

        Suggested by Darin Fisher.

        Improve the fix for bug 25355: Crash when Creating New Tab or New Window when set to open Same Page
        https://bugs.webkit.org/show_bug.cgi?id=25355
        rdar://problem/6823543

        * loader/FrameLoader.cpp:
        (WebCore::FrameLoader::loadItem): Allow shouldScroll to be true even if m_currentHistoryItem is 0.
        Not sure if when this case can really arise in practice, but it's good to match the original
        logic more closely.



git-svn-id: svn://svn.chromium.org/blink/trunk@42876 bbb929c8-8fbe-4397-9dbb-9b2b20218538
parent 57ef91e7
2009-04-26 Darin Adler <darin@apple.com>
Suggested by Darin Fisher.
Improve the fix for bug 25355: Crash when Creating New Tab or New Window when set to open Same Page
https://bugs.webkit.org/show_bug.cgi?id=25355
rdar://problem/6823543
* loader/FrameLoader.cpp:
(WebCore::FrameLoader::loadItem): Allow shouldScroll to be true even if m_currentHistoryItem is 0.
Not sure if when this case can really arise in practice, but it's good to match the original
logic more closely.
2009-04-25 Dirk Schulze <krit@webkit.org> 2009-04-25 Dirk Schulze <krit@webkit.org>
Reviewed by Oliver Hunt. Reviewed by Oliver Hunt.
...@@ -4458,7 +4458,7 @@ void FrameLoader::loadItem(HistoryItem* item, FrameLoadType loadType) ...@@ -4458,7 +4458,7 @@ void FrameLoader::loadItem(HistoryItem* item, FrameLoadType loadType)
// check for all that as an additional optimization. // check for all that as an additional optimization.
// We also do not do anchor-style navigation if we're posting a form or navigating from // We also do not do anchor-style navigation if we're posting a form or navigating from
// a page that was resulted from a form post. // a page that was resulted from a form post.
bool shouldScroll = m_currentHistoryItem && !formData && !m_currentHistoryItem->formData() && urlsMatchItem(item); bool shouldScroll = !formData && !(m_currentHistoryItem && m_currentHistoryItem->formData()) && urlsMatchItem(item);
#if ENABLE(WML) #if ENABLE(WML)
if (m_frame->document()->isWMLDocument()) if (m_frame->document()->isWMLDocument())
......
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