Fixes possible crash in Browser::OpenApplicationTab. The problem is
that OpenURL() may swap WebContents (can happen with
pre-rendering). If OpenURL did swap the WebContents, and we need to
pin the tab then we reset tab_index to -1 and ActivateTabAt crashes.

BUG=124689
TEST=none (test scenario is hard to exercise)
[email protected]

Review URL: https://chromiumcodereview.appspot.com/10313004

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@134986 0039d316-1c4b-4281-b951-d872f2087c98
1 file changed