summaryrefslogtreecommitdiffstats
path: root/chrome/installer/gcapi
diff options
context:
space:
mode:
authorthakis <thakis@chromium.org>2014-08-30 16:43:55 -0700
committerCommit bot <commit-bot@chromium.org>2014-08-30 23:46:22 +0000
commit36c364b15726fd8c9dd05ab492ff640bfda861f4 (patch)
tree5981f11bc463615c13bd5d5e6d7ecb6d67871a53 /chrome/installer/gcapi
parent256383aa0d253e3413a295fd376d3b289d236af3 (diff)
downloadchromium_src-36c364b15726fd8c9dd05ab492ff640bfda861f4.zip
chromium_src-36c364b15726fd8c9dd05ab492ff640bfda861f4.tar.gz
chromium_src-36c364b15726fd8c9dd05ab492ff640bfda861f4.tar.bz2
Revert of clang/win: Fix a few warnings in targets not in chromium_builder_tests. (patchset #3 id:40001 of https://codereview.chromium.org/526513002/)
Reason for revert: Speculative, might have broken InstallerStateTest.InitializeTwice on XP: http://build.chromium.org/p/chromium.win/builders/XP%20Tests%20%281%29/builds/32481 InstallerStateTest.InitializeTwice (run #1): [ RUN ] InstallerStateTest.InitializeTwice c:\b\build\slave\win_builder\build\src\chrome\installer\util\installer_state_unittest.cc(639): error: Value of: wcsstr(installer_state.target_path().value().c_str(), BrowserDistribution::GetSpecificDistribution( BrowserDistribution::CHROME_BINARIES)-> GetInstallSubDir().c_str()) Actual: false Expected: true [ FAILED ] InstallerStateTest.InitializeTwice (219 ms) InstallerStateTest.InitializeTwice (run #2): [ RUN ] InstallerStateTest.InitializeTwice c:\b\build\slave\win_builder\build\src\chrome\installer\util\installer_state_unittest.cc(639): error: Value of: wcsstr(installer_state.target_path().value().c_str(), BrowserDistribution::GetSpecificDistribution( BrowserDistribution::CHROME_BINARIES)-> GetInstallSubDir().c_str()) Actual: false Expected: true [ FAILED ] InstallerStateTest.InitializeTwice (109 ms) Original issue's description: > clang/win: Fix a few warnings in targets not in chromium_builder_tests. > > Also don't use "default" as a variable name, as it's a keyword. > Also fix a bug where a wstring was passed to %ls. > > No real behavior change. > > BUG=82385 > R=hans@chromium.org > TBR=cpu, vitalybuka > > Committed to pending queue: https://chromium.googlesource.com/chromium/src/+/d7efa09 TBR=hans@chromium.org,robertshield@chromium.org,gab@chromium.org,vitalybuka@chromium.org,cpu@chromium.org NOTREECHECKS=true NOTRY=true BUG=82385 Review URL: https://codereview.chromium.org/519463003 Cr-Commit-Position: refs/heads/master@{#292809}
Diffstat (limited to 'chrome/installer/gcapi')
-rw-r--r--chrome/installer/gcapi/gcapi.cc2
-rw-r--r--chrome/installer/gcapi/gcapi.h2
-rw-r--r--chrome/installer/gcapi/gcapi_last_run_test.cc2
3 files changed, 3 insertions, 3 deletions
diff --git a/chrome/installer/gcapi/gcapi.cc b/chrome/installer/gcapi/gcapi.cc
index ce0d22a..7253935 100644
--- a/chrome/installer/gcapi/gcapi.cc
+++ b/chrome/installer/gcapi/gcapi.cc
@@ -672,7 +672,7 @@ BOOL __stdcall CanOfferReactivation(const wchar_t* brand_code,
return TRUE;
}
-BOOL __stdcall ReactivateChrome(const wchar_t* brand_code,
+BOOL __stdcall ReactivateChrome(wchar_t* brand_code,
int shell_mode,
DWORD* error_code) {
BOOL result = FALSE;
diff --git a/chrome/installer/gcapi/gcapi.h b/chrome/installer/gcapi/gcapi.h
index 81a59b5..a35293e 100644
--- a/chrome/installer/gcapi/gcapi.h
+++ b/chrome/installer/gcapi/gcapi.h
@@ -113,7 +113,7 @@ BOOL __stdcall CanOfferReactivation(const wchar_t* brand_code,
// |shell_mode| should be set to one of GCAPI_INVOKED_STANDARD_SHELL or
// GCAPI_INVOKED_UAC_ELEVATION depending on whether this method is invoked
// from an elevated or non-elevated process.
-BOOL __stdcall ReactivateChrome(const wchar_t* brand_code,
+BOOL __stdcall ReactivateChrome(wchar_t* brand_code,
int shell_mode,
DWORD* error_code);
diff --git a/chrome/installer/gcapi/gcapi_last_run_test.cc b/chrome/installer/gcapi/gcapi_last_run_test.cc
index 9dbd706..8f07a3b 100644
--- a/chrome/installer/gcapi/gcapi_last_run_test.cc
+++ b/chrome/installer/gcapi/gcapi_last_run_test.cc
@@ -27,7 +27,7 @@ class GCAPILastRunTest : public ::testing::Test {
void SetUp() {
// Override keys - this is undone during destruction.
std::wstring hkcu_override = base::StringPrintf(
- L"hkcu_override\\%ls", base::ASCIIToWide(base::GenerateGUID()).c_str());
+ L"hkcu_override\\%ls", base::ASCIIToWide(base::GenerateGUID()));
override_manager_.OverrideRegistry(HKEY_CURRENT_USER, hkcu_override);
// Create the client state key in the right places.