summaryrefslogtreecommitdiffstats
path: root/WebCore/loader/FrameLoader.cpp
diff options
context:
space:
mode:
authorLeon Clarke <leonclarke@google.com>2010-06-03 14:33:32 +0100
committerLeon Clarke <leonclarke@google.com>2010-06-08 12:24:51 +0100
commit5af96e2c7b73ebc627c6894727826a7576d31758 (patch)
treef9d5e6f6175ccd7e3d14de9b290f08937a0d17ba /WebCore/loader/FrameLoader.cpp
parent8cc4fcf4f6adcbc0e0aebfc24fbad9a4cddf2cfb (diff)
downloadexternal_webkit-5af96e2c7b73ebc627c6894727826a7576d31758.zip
external_webkit-5af96e2c7b73ebc627c6894727826a7576d31758.tar.gz
external_webkit-5af96e2c7b73ebc627c6894727826a7576d31758.tar.bz2
Merge webkit.org at r60469 : Initial merge by git.
Change-Id: I66a0047aa2af802f66bb0c7f2a8b02247a596234
Diffstat (limited to 'WebCore/loader/FrameLoader.cpp')
-rw-r--r--WebCore/loader/FrameLoader.cpp12
1 files changed, 5 insertions, 7 deletions
diff --git a/WebCore/loader/FrameLoader.cpp b/WebCore/loader/FrameLoader.cpp
index 6fcdcbe..8920b6a 100644
--- a/WebCore/loader/FrameLoader.cpp
+++ b/WebCore/loader/FrameLoader.cpp
@@ -60,7 +60,6 @@
#include "FrameLoaderClient.h"
#include "FrameTree.h"
#include "FrameView.h"
-#include "Geolocation.h"
#include "HTMLAnchorElement.h"
#include "HTMLAppletElement.h"
#include "HTMLFormElement.h"
@@ -78,7 +77,6 @@
#include "Logging.h"
#include "MIMETypeRegistry.h"
#include "MainResourceLoader.h"
-#include "Navigator.h"
#include "Page.h"
#include "PageCache.h"
#include "PageGroup.h"
@@ -624,11 +622,6 @@ void FrameLoader::stopLoading(UnloadEventPolicy unloadEventPolicy, DatabasePolic
#endif
}
- // Stop the Geolocation object, if present. This call is made after the unload
- // event has fired, so no new Geolocation activity is possible.
- if (m_frame->domWindow()->navigator()->optionalGeolocation())
- m_frame->domWindow()->navigator()->optionalGeolocation()->stop();
-
// tell all subframes to stop as well
for (Frame* child = m_frame->tree()->firstChild(); child; child = child->tree()->nextSibling())
child->loader()->stopLoading(unloadEventPolicy);
@@ -2196,6 +2189,7 @@ static bool canAccessAncestor(const SecurityOrigin* activeSecurityOrigin, Frame*
if (!targetFrame)
return false;
+ const bool isLocalActiveOrigin = activeSecurityOrigin->isLocal();
for (Frame* ancestorFrame = targetFrame; ancestorFrame; ancestorFrame = ancestorFrame->tree()->parent()) {
Document* ancestorDocument = ancestorFrame->document();
if (!ancestorDocument)
@@ -2204,6 +2198,10 @@ static bool canAccessAncestor(const SecurityOrigin* activeSecurityOrigin, Frame*
const SecurityOrigin* ancestorSecurityOrigin = ancestorDocument->securityOrigin();
if (activeSecurityOrigin->canAccess(ancestorSecurityOrigin))
return true;
+
+ // Allow file URL descendant navigation even when allowFileAccessFromFileURLs is false.
+ if (isLocalActiveOrigin && ancestorSecurityOrigin->isLocal())
+ return true;
}
return false;