diff options
author | robertshield@chromium.org <robertshield@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-02-14 06:03:37 +0000 |
---|---|---|
committer | robertshield@chromium.org <robertshield@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-02-14 06:03:37 +0000 |
commit | e245d2ca1c52403b7f15cd800d728b8468e3d117 (patch) | |
tree | a350438d4b19a99da58ebe20b1900b79b4ca622f /chrome_frame | |
parent | b8d6e06f4e2f41cb5148582eab2b91a32a7fc83a (diff) | |
download | chromium_src-e245d2ca1c52403b7f15cd800d728b8468e3d117.zip chromium_src-e245d2ca1c52403b7f15cd800d728b8468e3d117.tar.gz chromium_src-e245d2ca1c52403b7f15cd800d728b8468e3d117.tar.bz2 |
Fix COM initialization in chrome_frame_tests.exe when built with the ATL included with VS2010.
BUG=114609
TEST=chrome_frame_tests.exe
Review URL: http://codereview.chromium.org/9391014
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@121852 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome_frame')
-rw-r--r-- | chrome_frame/test/run_all_unittests.cc | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/chrome_frame/test/run_all_unittests.cc b/chrome_frame/test/run_all_unittests.cc index 6a1aa1b..5a0e40a 100644 --- a/chrome_frame/test/run_all_unittests.cc +++ b/chrome_frame/test/run_all_unittests.cc @@ -8,6 +8,7 @@ #include "base/process_util.h" #include "base/test/test_suite.h" #include "base/threading/platform_thread.h" +#include "base/win/scoped_com_initializer.h" #include "chrome/common/chrome_paths.h" #include "chrome_frame/crash_server_init.h" #include "chrome_frame/test/chrome_frame_test_utils.h" @@ -18,10 +19,6 @@ // To enable ATL-based code to run in this module class ChromeFrameUnittestsModule : public CAtlExeModuleT<ChromeFrameUnittestsModule> { - public: - static HRESULT InitializeCom() { - return CoInitializeEx(NULL, COINIT_APARTMENTTHREADED); - } }; ChromeFrameUnittestsModule _AtlModule; @@ -34,6 +31,7 @@ void PureCall() { } int main(int argc, char **argv) { + base::win::ScopedCOMInitializer com_initializer; ScopedChromeFrameRegistrar::RegisterAndExitProcessIfDirected(); base::EnableTerminationOnHeapCorruption(); base::PlatformThread::SetName("ChromeFrame tests"); |