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

Unified Diff: recovery/repair_exe/custom_action/testelevateusingmsp.cc

Issue 624713003: Keep only base/extractor.[cc|h]. (Closed) Base URL: https://chromium.googlesource.com/external/omaha.git@master
Patch Set: Created 6 years, 2 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « recovery/repair_exe/custom_action/executecustomaction.def ('k') | recovery/repair_exe/msp/build.scons » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: recovery/repair_exe/custom_action/testelevateusingmsp.cc
diff --git a/recovery/repair_exe/custom_action/testelevateusingmsp.cc b/recovery/repair_exe/custom_action/testelevateusingmsp.cc
deleted file mode 100644
index f1f971429be27ee99e0d3f4768ffc39e9b5c42d7..0000000000000000000000000000000000000000
--- a/recovery/repair_exe/custom_action/testelevateusingmsp.cc
+++ /dev/null
@@ -1,59 +0,0 @@
-// Copyright 2007-2009 Google Inc.
-//
-// Licensed under the Apache License, Version 2.0 (the "License");
-// you may not use this file except in compliance with the License.
-// You may obtain a copy of the License at
-//
-// http://www.apache.org/licenses/LICENSE-2.0
-//
-// Unless required by applicable law or agreed to in writing, software
-// distributed under the License is distributed on an "AS IS" BASIS,
-// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-// See the License for the specific language governing permissions and
-// limitations under the License.
-// ========================================================================
-//
-// Command line utility that elevates an executable using an MSI Patch.
-// The MSI patch is assumed to be in the same directory as this executable.
-
-#include <windows.h>
-#include <atlstr.h>
-#include "omaha/base/constants.h"
-#include "omaha/recovery/repair_exe/mspexecutableelevator.h"
-
-int main(int argc, char** argv) {
- DWORD process_id = 0;
- if (2 <= argc) {
- CString arguments;
- if (3 <= argc) {
- arguments = argv[2];
- }
- HANDLE process = NULL;
- HRESULT hr = omaha::msp_executable_elevator::ExecuteGoogleSignedExe(
- CString(argv[1]),
- arguments,
- omaha::kHelperInstallerProductGuid,
- omaha::kHelperPatchGuid,
- omaha::kHelperPatchName,
- &process);
- if (process) {
- process_id = ::GetProcessId(process);
- ::CloseHandle(process);
- }
- wprintf(_T("%s (process handle:%x process id: %u hresult:%x)"),
- (SUCCEEDED(hr) ? _T("Success") : _T("Failure")),
- process,
- process_id,
- static_cast<int>(hr));
- } else {
- static TCHAR explain_test[] =
- _T("testelevateusingmsp\n\n")
- _T("To use this test, pass the full path to an executable containing ")
- _T("the Google Update Repair resource and is signed with a Google ")
- _T("code-signing certificate that has a certain subject and ")
- _T("organization unit name.")
- _T("\n\nAn optional parameter to that executable may be passed as well.");
- wprintf(explain_test);
- }
- return process_id;
-}
« no previous file with comments | « recovery/repair_exe/custom_action/executecustomaction.def ('k') | recovery/repair_exe/msp/build.scons » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698