Fixes a reuse WebUI bug because of the incorrect shadowing of a boolean value.
commit6454936159376e371fd27c2a14e27b18494850d7
authorcarlosk <carlosk@chromium.org>
Thu, 26 Mar 2015 22:41:51 +0000 (26 15:41 -0700)
committerCommit bot <commit-bot@chromium.org>
Thu, 26 Mar 2015 22:42:25 +0000 (26 22:42 +0000)
tree81b186c77f7ec34707c627be6716e248a46239fa
parent914e56aa991cb783e655965a06b5b88cf757968c
Fixes a reuse WebUI bug because of the incorrect shadowing of a boolean value.

This only affects PlzNavigate. When a same-site navigation should reuse the current WebUI, in RFHM::GetFrameHostForNavigation the (shadowing) method-local |should_reuse_web_ui_| would be set to true and the speculative WebUI would (correctly) not be created. But later on as the instance-level |should_reuse_web_ui_| defaults to false, RFHM::CommitPending would try to get the |speculative_web_ui_| which would not be set and *could* cause a crash. As of now the crash doesn't happen because CommitPending is not called when the current RFH is kept for the navigation.

BUG=376094

Review URL: https://codereview.chromium.org/1012863004

Cr-Commit-Position: refs/heads/master@{#322485}
content/browser/frame_host/render_frame_host_manager.cc