From 36c364b15726fd8c9dd05ab492ff640bfda861f4 Mon Sep 17 00:00:00 2001 From: thakis Date: Sat, 30 Aug 2014 16:43:55 -0700 Subject: 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} --- rlz/win/lib/machine_deal_test.cc | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'rlz') diff --git a/rlz/win/lib/machine_deal_test.cc b/rlz/win/lib/machine_deal_test.cc index ec0526f..47b7265 100644 --- a/rlz/win/lib/machine_deal_test.cc +++ b/rlz/win/lib/machine_deal_test.cc @@ -72,7 +72,7 @@ TEST_F(MachineDealCodeTest, SetFromPingResponse) { // Bad responses - const char kBadDccResponse[] = + char* kBadDccResponse = "dcc: NotMyDCCode \r\n" "set_dcc: NewDCCode\r\n" "crc32: 1B4D6BB3"; @@ -81,7 +81,7 @@ TEST_F(MachineDealCodeTest, SetFromPingResponse) { EXPECT_TRUE(rlz_lib::MachineDealCode::Get(dcc_50, 50)); EXPECT_STREQ("MyDCCode", dcc_50); - const char kBadCrcResponse[] = + char* kBadCrcResponse = "dcc: MyDCCode \r\n" "set_dcc: NewDCCode\r\n" "crc32: 90707106"; @@ -92,7 +92,7 @@ TEST_F(MachineDealCodeTest, SetFromPingResponse) { // Good responses - const char kMissingSetResponse[] = + char* kMissingSetResponse = "dcc: MyDCCode \r\n" "crc32: 35F2E717"; EXPECT_TRUE(rlz_lib::MachineDealCode::SetFromPingResponse( @@ -100,7 +100,7 @@ TEST_F(MachineDealCodeTest, SetFromPingResponse) { EXPECT_TRUE(rlz_lib::MachineDealCode::Get(dcc_50, 50)); EXPECT_STREQ("MyDCCode", dcc_50); - const char kGoodResponse[] = + char* kGoodResponse = "dcc: MyDCCode \r\n" "set_dcc: NewDCCode\r\n" "crc32: C8540E02"; @@ -109,7 +109,7 @@ TEST_F(MachineDealCodeTest, SetFromPingResponse) { EXPECT_TRUE(rlz_lib::MachineDealCode::Get(dcc_50, 50)); EXPECT_STREQ("NewDCCode", dcc_50); - const char kGoodResponse2[] = + char* kGoodResponse2 = "set_dcc: NewDCCode2 \r\n" "dcc: NewDCCode \r\n" "crc32: 60B6409A"; @@ -119,7 +119,7 @@ TEST_F(MachineDealCodeTest, SetFromPingResponse) { EXPECT_STREQ("NewDCCode2", dcc_50); MachineDealCodeHelper::Clear(); - const char kGoodResponse3[] = + char* kGoodResponse3 = "set_dcc: NewDCCode \r\n" "crc32: 374C1C47"; EXPECT_TRUE(rlz_lib::MachineDealCode::SetFromPingResponse( @@ -128,7 +128,7 @@ TEST_F(MachineDealCodeTest, SetFromPingResponse) { EXPECT_STREQ("NewDCCode", dcc_50); MachineDealCodeHelper::Clear(); - const char kGoodResponse4[] = + char* kGoodResponse4 = "dcc: \r\n" "set_dcc: NewDCCode \r\n" "crc32: 0AB1FB39"; -- cgit v1.1