summaryrefslogtreecommitdiffstats
path: root/chrome
diff options
context:
space:
mode:
authorshishir@chromium.org <shishir@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-01-08 21:56:34 +0000
committershishir@chromium.org <shishir@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-01-08 21:56:34 +0000
commit546df3bc7432d38be3caa7e30bf531e808b80b2b (patch)
treece860b3fb913fd504b770dbf50c06c7fd4ef33c7 /chrome
parentc6cbd3a5b7f2292c6a86877230d3fc63f668d05e (diff)
downloadchromium_src-546df3bc7432d38be3caa7e30bf531e808b80b2b.zip
chromium_src-546df3bc7432d38be3caa7e30bf531e808b80b2b.tar.gz
chromium_src-546df3bc7432d38be3caa7e30bf531e808b80b2b.tar.bz2
Do not commit InstantLoader server redirects till the page supports instant.
This will allow the instant page to redirect based on country specific pages. The change is a somewhat temporary fix and will be redundant when InstantLoader lives in its own privileged process. BUG=167982 Review URL: https://chromiumcodereview.appspot.com/11785025 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@175585 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome')
-rw-r--r--chrome/browser/instant/instant_controller.cc6
1 files changed, 6 insertions, 0 deletions
diff --git a/chrome/browser/instant/instant_controller.cc b/chrome/browser/instant/instant_controller.cc
index 5077a87..14746e5 100644
--- a/chrome/browser/instant/instant_controller.cc
+++ b/chrome/browser/instant/instant_controller.cc
@@ -870,6 +870,12 @@ void InstantController::InstantLoaderRenderViewGone() {
}
void InstantController::InstantLoaderAboutToNavigateMainFrame(const GURL& url) {
+ // If the page does not yet support instant, we allow redirects and other
+ // navigations to go through since the instant URL can redirect - e.g. to
+ // country specific pages.
+ if (!loader_->supports_instant())
+ return;
+
GURL instant_url(loader_->instant_url());
// If we are navigating to the instant URL, do nothing.