diff options
author | stoyan@google.com <stoyan@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-10-26 18:15:59 +0000 |
---|---|---|
committer | stoyan@google.com <stoyan@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-10-26 18:15:59 +0000 |
commit | aff8a13ec56589a853f73686db770f2adad4ae2f (patch) | |
tree | a4e52750a3cc16e5a40de719da02403c97532b52 /base/message_loop.cc | |
parent | a2bf82f595bf80542ea5011656a86f8fc89e17ee (diff) | |
download | chromium_src-aff8a13ec56589a853f73686db770f2adad4ae2f.zip chromium_src-aff8a13ec56589a853f73686db770f2adad4ae2f.tar.gz chromium_src-aff8a13ec56589a853f73686db770f2adad4ae2f.tar.bz2 |
Move creation of SEH frame into a separate funcion.For any function that uses SEH, the compiler creates a single EXCEPTION_REGISTRATION record at the function prolog (even if the function has nested or inside condition statement __try/__except constructs). When __try block is entered and leaved only the index to the relevant scope table is updated.When the exception occurs the __except_handler4 may ignore it if there is no scope table set i.e. we are outside __try block.In ChromeFrame when exception happens, the global vectored exception filter walks through the SEH chain and is misled that there is handler/filter installed and therefore skips creation of a crashdump.
BUG=23845
TEST=crashes in ChromeFrame background threads are reported.
Review URL: http://codereview.chromium.org/335011
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@30066 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'base/message_loop.cc')
-rw-r--r-- | base/message_loop.cc | 18 |
1 files changed, 12 insertions, 6 deletions
diff --git a/base/message_loop.cc b/base/message_loop.cc index bf5256a..ddca7dbf 100644 --- a/base/message_loop.cc +++ b/base/message_loop.cc @@ -169,18 +169,24 @@ void MessageLoop::RunAllPending() { void MessageLoop::RunHandler() { #if defined(OS_WIN) if (exception_restoration_) { - LPTOP_LEVEL_EXCEPTION_FILTER current_filter = GetTopSEHFilter(); - __try { - RunInternal(); - } __except(SEHFilter(current_filter)) { - } + RunInternalInSEHFrame(); return; } #endif RunInternal(); } - +//------------------------------------------------------------------------------ +#if defined(OS_WIN) +__declspec(noinline) void MessageLoop::RunInternalInSEHFrame() { + LPTOP_LEVEL_EXCEPTION_FILTER current_filter = GetTopSEHFilter(); + __try { + RunInternal(); + } __except(SEHFilter(current_filter)) { + } + return; +} +#endif //------------------------------------------------------------------------------ void MessageLoop::RunInternal() { |