summaryrefslogtreecommitdiffstats
path: root/chrome/installer/setup
diff options
context:
space:
mode:
authorNico Weber <thakis@chromium.org>2015-08-08 13:10:06 -0700
committerNico Weber <thakis@chromium.org>2015-08-08 20:12:28 +0000
commit334923f64adaf553b1eb44d4be0d1f94aefe8e2d (patch)
tree999d9f1e777219e0fe0803a7341ead1fc962c371 /chrome/installer/setup
parentb35ddf501b14f51de10b39ee2bffa35c4aff75f5 (diff)
downloadchromium_src-334923f64adaf553b1eb44d4be0d1f94aefe8e2d.zip
chromium_src-334923f64adaf553b1eb44d4be0d1f94aefe8e2d.tar.gz
chromium_src-334923f64adaf553b1eb44d4be0d1f94aefe8e2d.tar.bz2
clang/win: Try to fix build more after https://codereview.chromium.org/1261953003.
BUG=505316 TBR=robertshield Review URL: https://codereview.chromium.org/1274893006. Cr-Commit-Position: refs/heads/master@{#342539}
Diffstat (limited to 'chrome/installer/setup')
-rw-r--r--chrome/installer/setup/setup_main.cc34
1 files changed, 0 insertions, 34 deletions
diff --git a/chrome/installer/setup/setup_main.cc b/chrome/installer/setup/setup_main.cc
index 571964c..15998d1 100644
--- a/chrome/installer/setup/setup_main.cc
+++ b/chrome/installer/setup/setup_main.cc
@@ -1159,40 +1159,6 @@ bool HandleNonInstallCmdLineOptions(const InstallationState& original_state,
return handled;
}
-bool ShowRebootDialog() {
- // Get a token for this process.
- HANDLE token;
- if (!OpenProcessToken(GetCurrentProcess(),
- TOKEN_ADJUST_PRIVILEGES | TOKEN_QUERY,
- &token)) {
- LOG(ERROR) << "Failed to open token.";
- return false;
- }
-
- // Use a ScopedHandle to keep track of and eventually close our handle.
- // TODO(robertshield): Add a Receive() method to base's ScopedHandle.
- base::win::ScopedHandle scoped_handle(token);
-
- // Get the LUID for the shutdown privilege.
- TOKEN_PRIVILEGES tkp = {0};
- LookupPrivilegeValue(NULL, SE_SHUTDOWN_NAME, &tkp.Privileges[0].Luid);
- tkp.PrivilegeCount = 1;
- tkp.Privileges[0].Attributes = SE_PRIVILEGE_ENABLED;
-
- // Get the shutdown privilege for this process.
- AdjustTokenPrivileges(token, FALSE, &tkp, 0,
- reinterpret_cast<PTOKEN_PRIVILEGES>(NULL), 0);
- if (GetLastError() != ERROR_SUCCESS) {
- LOG(ERROR) << "Unable to get shutdown privileges.";
- return false;
- }
-
- // Popup a dialog that will prompt to reboot using the default system message.
- // TODO(robertshield): Add a localized, more specific string to the prompt.
- RestartDialog(NULL, NULL, EWX_REBOOT | EWX_FORCEIFHUNG);
- return true;
-}
-
// Returns the Custom information for the client identified by the exe path
// passed in. This information is used for crash reporting.
google_breakpad::CustomClientInfo* GetCustomInfo(const wchar_t* exe_path) {