diff options
author | tommi@chromium.org <tommi@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-08-10 14:09:37 +0000 |
---|---|---|
committer | tommi@chromium.org <tommi@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-08-10 14:09:37 +0000 |
commit | bbfa9a15797ba107dcae0f7fff85a7f12ffd26b9 (patch) | |
tree | ee15898939e4989b96c6419217696f63d7a5585b /chrome_frame/utils.cc | |
parent | e721ebe885b159f9b18047392be9a0f5834998fb (diff) | |
download | chromium_src-bbfa9a15797ba107dcae0f7fff85a7f12ffd26b9.zip chromium_src-bbfa9a15797ba107dcae0f7fff85a7f12ffd26b9.tar.gz chromium_src-bbfa9a15797ba107dcae0f7fff85a7f12ffd26b9.tar.bz2 |
Handle automation server crashes. When Chrome crashes, we now handle the case and support document refresh or reload.
When chrome crashes, we draw a poor man's sad tab (":-("), so that can clearly be improved.
Another thing is that if the chrome instance that crashed held several navigational entries, then that history is lost.
TEST=There are a couple of tests included, so run those (*TabCrash*) and also verify that when the chrome automation server is killed that we do the right thing. Also check info in bug report.
BUG=25839
Review URL: http://codereview.chromium.org/3061036
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@55565 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome_frame/utils.cc')
-rw-r--r-- | chrome_frame/utils.cc | 17 |
1 files changed, 13 insertions, 4 deletions
diff --git a/chrome_frame/utils.cc b/chrome_frame/utils.cc index bed5409..c92c0f1 100644 --- a/chrome_frame/utils.cc +++ b/chrome_frame/utils.cc @@ -1175,7 +1175,12 @@ std::string BindStatus2Str(ULONG bind_status) { } std::string PiFlags2Str(DWORD flags) { -#define ADD_PI_FLAG(x) if (flags & x) { s.append(#x ## " "); flags &= ~x; } +#define ADD_PI_FLAG(x) \ + if (flags & x) { \ + s.append(#x ## " "); \ + flags &= ~x; \ + } + std::string s = " flags "; ADD_PI_FLAG(PI_PARSE_URL); ADD_PI_FLAG(PI_FILTER_MODE); @@ -1200,7 +1205,12 @@ std::string PiFlags2Str(DWORD flags) { } std::string Bscf2Str(DWORD flags) { -#define ADD_BSCF_FLAG(x) if (flags & x) { s.append(#x ## " "); flags &= ~x; } +#define ADD_BSCF_FLAG(x) \ + if (flags & x) {\ + s.append(#x ## " "); \ + flags &= ~x; \ + } + std::string s = " flags "; ADD_BSCF_FLAG(BSCF_FIRSTDATANOTIFICATION) ADD_BSCF_FLAG(BSCF_INTERMEDIATEDATANOTIFICATION) @@ -1253,8 +1263,7 @@ bool ChromeFrameUrl::Parse(const std::wstring& url) { attach_to_external_tab_ = MatchPatternWide(url.c_str(), kChromeFrameAttachTabPattern); - is_chrome_protocol_ = StartsWith(url, kChromeProtocolPrefix, - false); + is_chrome_protocol_ = StartsWith(url, kChromeProtocolPrefix, false); DCHECK(!(attach_to_external_tab_ && is_chrome_protocol_)); if (is_chrome_protocol_) { url_.erase(0, lstrlen(kChromeProtocolPrefix)); |