Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(71)

Side by Side Diff: chrome/installer/util/self_reg_work_item.cc

Issue 1210013007: clang/win: Fix warnings to prepare for building without -Wno-reorder. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@clang-unsequenced
Patch Set: Created 5 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/installer/util/self_reg_work_item.h" 5 #include "chrome/installer/util/self_reg_work_item.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "base/strings/string_util.h" 8 #include "base/strings/string_util.h"
9 #include "base/strings/stringprintf.h" 9 #include "base/strings/stringprintf.h"
10 #include "chrome/installer/util/logging_installer.h" 10 #include "chrome/installer/util/logging_installer.h"
11 11
12 // Default registration export names. 12 // Default registration export names.
13 const char kDefaultRegistrationEntryPoint[] = "DllRegisterServer"; 13 const char kDefaultRegistrationEntryPoint[] = "DllRegisterServer";
14 const char kDefaultUnregistrationEntryPoint[] = "DllUnregisterServer"; 14 const char kDefaultUnregistrationEntryPoint[] = "DllUnregisterServer";
15 15
16 // User-level registration export names. 16 // User-level registration export names.
17 const char kUserRegistrationEntryPoint[] = "DllRegisterUserServer"; 17 const char kUserRegistrationEntryPoint[] = "DllRegisterUserServer";
18 const char kUserUnregistrationEntryPoint[] = "DllUnregisterUserServer"; 18 const char kUserUnregistrationEntryPoint[] = "DllUnregisterUserServer";
19 19
20 SelfRegWorkItem::SelfRegWorkItem(const std::wstring& dll_path, 20 SelfRegWorkItem::SelfRegWorkItem(const std::wstring& dll_path,
21 bool do_register, 21 bool do_register,
22 bool user_level_registration) 22 bool user_level_registration)
23 : do_register_(do_register), dll_path_(dll_path), 23 : dll_path_(dll_path),
24 do_register_(do_register),
24 user_level_registration_(user_level_registration) { 25 user_level_registration_(user_level_registration) {
25 } 26 }
26 27
27 SelfRegWorkItem::~SelfRegWorkItem() { 28 SelfRegWorkItem::~SelfRegWorkItem() {
28 } 29 }
29 30
30 // This is designed to unmux error codes that may be shoe-horned in to HRESULT 31 // This is designed to unmux error codes that may be shoe-horned in to HRESULT
31 // return codes by ORing a number into the top four bits of the facility code 32 // return codes by ORing a number into the top four bits of the facility code
32 // Any number thus found will be returned in |error_code|. The "cleaned" 33 // Any number thus found will be returned in |error_code|. The "cleaned"
33 // HRESULT is then returned. 34 // HRESULT is then returned.
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after
94 if (ignore_failure_) 95 if (ignore_failure_)
95 success = true; 96 success = true;
96 return success; 97 return success;
97 } 98 }
98 99
99 void SelfRegWorkItem::Rollback() { 100 void SelfRegWorkItem::Rollback() {
100 if (!ignore_failure_) { 101 if (!ignore_failure_) {
101 RegisterDll(!do_register_); 102 RegisterDll(!do_register_);
102 } 103 }
103 } 104 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698