diff options
author | tfarina@chromium.org <tfarina@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-01-09 16:32:20 +0000 |
---|---|---|
committer | tfarina@chromium.org <tfarina@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-01-09 16:32:20 +0000 |
commit | b90d7e80c20c7c20831bedfe3fa6028ddab1ae95 (patch) | |
tree | 308e927055c27a533019d329a9677ce8e7c53e33 /ceee | |
parent | d716d4178136a223e9e79b3508c755a71108a068 (diff) | |
download | chromium_src-b90d7e80c20c7c20831bedfe3fa6028ddab1ae95.zip chromium_src-b90d7e80c20c7c20831bedfe3fa6028ddab1ae95.tar.gz chromium_src-b90d7e80c20c7c20831bedfe3fa6028ddab1ae95.tar.bz2 |
Reland "Remove base/scoped_handle_win.h."
Fixed the problem with rlz library. Now should be fine to land this again.
This reverts commit 3620d9501af7bff688862c54fdd60f7eb41797f3.
Original Review URL: http://codereview.chromium.org/6126002/
BUG=None
TEST=trybots
Review URL: http://codereview.chromium.org/6110005
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@70861 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'ceee')
-rw-r--r-- | ceee/common/process_utils_win.cc | 13 | ||||
-rw-r--r-- | ceee/ie/common/chrome_frame_host.h | 6 | ||||
-rw-r--r-- | ceee/ie/plugin/bho/executor_com_unittest.cc | 6 |
3 files changed, 13 insertions, 12 deletions
diff --git a/ceee/common/process_utils_win.cc b/ceee/common/process_utils_win.cc index 80df821..239bbfe 100644 --- a/ceee/common/process_utils_win.cc +++ b/ceee/common/process_utils_win.cc @@ -1,4 +1,4 @@ -// Copyright (c) 2010 The Chromium Authors. All rights reserved. +// Copyright (c) 2011 The Chromium Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. // @@ -9,24 +9,23 @@ #include <sddl.h> #include "base/logging.h" -#include "base/scoped_handle.h" +#include "base/win/scoped_handle.h" #include "base/win/windows_version.h" #include "ceee/common/com_utils.h" - namespace process_utils_win { HRESULT SetThreadIntegrityLevel(HANDLE* thread, const std::wstring& level) { HANDLE temp_handle = NULL; BOOL success = ::OpenProcessToken( ::GetCurrentProcess(), MAXIMUM_ALLOWED, &temp_handle); - ScopedHandle process_token(temp_handle); + base::win::ScopedHandle process_token(temp_handle); temp_handle = NULL; if (success) { success = ::DuplicateTokenEx( process_token, MAXIMUM_ALLOWED, NULL, SecurityImpersonation, TokenImpersonation, &temp_handle); - ScopedHandle mic_token(temp_handle); + base::win::ScopedHandle mic_token(temp_handle); temp_handle = NULL; if (success) { PSID mic_sid = NULL; @@ -98,7 +97,7 @@ HRESULT IsCurrentProcessUacElevated(bool* running_as_admin) { // All that for an admin-group member, who can run in elevated mode. // This logic applies to Vista/Win7. The case of earlier systems is handled // at the start. - ScopedHandle process_token(temp_handle); + base::win::ScopedHandle process_token(temp_handle); TOKEN_ELEVATION_TYPE elevation_type = TokenElevationTypeDefault; DWORD variable_len_dummy = 0; if (!::GetTokenInformation(process_token, TokenElevationType, &elevation_type, @@ -331,4 +330,4 @@ void ProcessCompatibilityCheck::ResetState() { GetInstance()->StandardInitialize(); } -} // namespace com +} // namespace process_utils_win diff --git a/ceee/ie/common/chrome_frame_host.h b/ceee/ie/common/chrome_frame_host.h index 4703e71..59e5c9f 100644 --- a/ceee/ie/common/chrome_frame_host.h +++ b/ceee/ie/common/chrome_frame_host.h @@ -1,4 +1,4 @@ -// Copyright (c) 2010 The Chromium Authors. All rights reserved. +// Copyright (c) 2011 The Chromium Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. // @@ -12,7 +12,7 @@ #include <list> #include "base/basictypes.h" -#include "base/scoped_handle.h" +#include "base/win/scoped_handle.h" #include "ceee/common/initializing_coclass.h" #include "chrome_tab.h" // NOLINT @@ -212,7 +212,7 @@ class ATL_NO_VTABLE ChromeFrameHost #ifndef NDEBUG // We use a cross process event to make sure there is only one chrome frame // host that returns ExtensionApisToAutomate... But only needed for a DCHECK. - ScopedHandle automating_extension_api_; + base::win::ScopedHandle automating_extension_api_; #endif // A cached BSTR for the posted messages origin (which is kAutomationOrigin). diff --git a/ceee/ie/plugin/bho/executor_com_unittest.cc b/ceee/ie/plugin/bho/executor_com_unittest.cc index 8478825..61d5a47 100644 --- a/ceee/ie/plugin/bho/executor_com_unittest.cc +++ b/ceee/ie/plugin/bho/executor_com_unittest.cc @@ -1,4 +1,4 @@ -// Copyright (c) 2010 The Chromium Authors. All rights reserved. +// Copyright (c) 2011 The Chromium Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. // @@ -8,6 +8,7 @@ #include <shlobj.h> #include <atlbase.h> + #include "base/command_line.h" #include "base/file_path.h" #include "base/message_loop.h" @@ -15,6 +16,7 @@ #include "base/process_util.h" #include "base/threading/thread.h" #include "base/win/registry.h" +#include "base/win/scoped_handle.h" #include "base/win/windows_version.h" #include "ceee/common/initializing_coclass.h" #include "ceee/ie/plugin/toolband/toolband_proxy.h" @@ -159,7 +161,7 @@ class RemoteObjectHost { } void RunSync(Task* task) { - ScopedHandle event(::CreateEvent(NULL, TRUE, FALSE, NULL)); + base::win::ScopedHandle event(::CreateEvent(NULL, TRUE, FALSE, NULL)); remote_thread_.message_loop()->PostTask(FROM_HERE, task); remote_thread_.message_loop()->PostTask(FROM_HERE, |