summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--AUTHORS1
-rw-r--r--base/pickle_unittest.cc4
-rw-r--r--base/string_number_conversions_unittest.cc2
-rw-r--r--chrome/browser/password_manager/password_store_x_unittest.cc2
-rw-r--r--chrome/browser/predictors/autocomplete_action_predictor_unittest.cc2
-rw-r--r--gpu/command_buffer/tests/gl_pointcoord_unittest.cc12
-rw-r--r--net/base/x509_util_nss_unittest.cc4
-rw-r--r--net/cookies/cookie_monster_perftest.cc4
-rw-r--r--net/cookies/cookie_monster_unittest.cc14
-rw-r--r--net/spdy/spdy_http_stream_spdy3_unittest.cc4
-rw-r--r--net/spdy/spdy_test_util_spdy2.cc6
-rw-r--r--net/spdy/spdy_test_util_spdy2.h6
-rw-r--r--net/spdy/spdy_test_util_spdy3.cc6
-rw-r--r--net/spdy/spdy_test_util_spdy3.h6
-rw-r--r--sync/internal_api/sync_encryption_handler_impl_unittest.cc2
15 files changed, 35 insertions, 40 deletions
diff --git a/AUTHORS b/AUTHORS
index 02a1277..3edfe02 100644
--- a/AUTHORS
+++ b/AUTHORS
@@ -213,3 +213,4 @@ Yang Gu <yang.gu@intel.com>
Timo Reimann <ttr314@googlemail.com>
Sungguk Lim <limasdf@gmail.com>
Martin Bednorz <m.s.bednorz@gmail.com>
+Kamil Jiwa <kamil.jiwa@gmail.com>
diff --git a/base/pickle_unittest.cc b/base/pickle_unittest.cc
index c866acd..5a4d6a0 100644
--- a/base/pickle_unittest.cc
+++ b/base/pickle_unittest.cc
@@ -40,9 +40,9 @@ void VerifyResult(const Pickle& pickle) {
bool outbool;
EXPECT_TRUE(pickle.ReadBool(&iter, &outbool));
- EXPECT_EQ(testbool1, outbool);
+ EXPECT_FALSE(outbool);
EXPECT_TRUE(pickle.ReadBool(&iter, &outbool));
- EXPECT_EQ(testbool2, outbool);
+ EXPECT_TRUE(outbool);
uint16 outuint16;
EXPECT_TRUE(pickle.ReadUInt16(&iter, &outuint16));
diff --git a/base/string_number_conversions_unittest.cc b/base/string_number_conversions_unittest.cc
index 78fde7a..0438df0 100644
--- a/base/string_number_conversions_unittest.cc
+++ b/base/string_number_conversions_unittest.cc
@@ -203,7 +203,7 @@ TEST(StringNumberConversionsTest, StringToInt64) {
TEST(StringNumberConversionsTest, HexStringToInt) {
static const struct {
std::string input;
- int output;
+ int64 output;
bool success;
} cases[] = {
{"0", 0, true},
diff --git a/chrome/browser/password_manager/password_store_x_unittest.cc b/chrome/browser/password_manager/password_store_x_unittest.cc
index 2387968..cb0ec28 100644
--- a/chrome/browser/password_manager/password_store_x_unittest.cc
+++ b/chrome/browser/password_manager/password_store_x_unittest.cc
@@ -246,7 +246,7 @@ void InitExpectedForms(bool autofillable, size_t count, VectorOfForms* forms) {
L"password_element",
autofillable ? L"username_value" : NULL,
autofillable ? L"password_value" : NULL,
- autofillable, false, i + 1 };
+ autofillable, false, static_cast<double>(i + 1) };
forms->push_back(CreatePasswordFormFromData(data));
}
}
diff --git a/chrome/browser/predictors/autocomplete_action_predictor_unittest.cc b/chrome/browser/predictors/autocomplete_action_predictor_unittest.cc
index b785459..e9799dd 100644
--- a/chrome/browser/predictors/autocomplete_action_predictor_unittest.cc
+++ b/chrome/browser/predictors/autocomplete_action_predictor_unittest.cc
@@ -155,8 +155,6 @@ class AutocompleteActionPredictorTest : public testing::Test {
}
std::string AddRow(const TestUrlInfo& test_row) {
- AutocompleteActionPredictor::DBCacheKey key = { test_row.user_text,
- test_row.url };
AutocompleteActionPredictorTable::Row row =
CreateRowFromTestUrlInfo(test_row);
predictor_->AddAndUpdateRows(
diff --git a/gpu/command_buffer/tests/gl_pointcoord_unittest.cc b/gpu/command_buffer/tests/gl_pointcoord_unittest.cc
index cf41927..5073ad3 100644
--- a/gpu/command_buffer/tests/gl_pointcoord_unittest.cc
+++ b/gpu/command_buffer/tests/gl_pointcoord_unittest.cc
@@ -40,10 +40,10 @@ GLuint PointCoordTest::SetupQuad(
glGenBuffers(1, &vbo);
glBindBuffer(GL_ARRAY_BUFFER, vbo);
float vertices[] = {
- -0.5 + pixel_offset, -0.5 + pixel_offset,
- 0.5 + pixel_offset, -0.5 + pixel_offset,
- -0.5 + pixel_offset, 0.5 + pixel_offset,
- 0.5 + pixel_offset, 0.5 + pixel_offset,
+ -0.5f + pixel_offset, -0.5f + pixel_offset,
+ 0.5f + pixel_offset, -0.5f + pixel_offset,
+ -0.5f + pixel_offset, 0.5f + pixel_offset,
+ 0.5f + pixel_offset, 0.5f + pixel_offset,
};
glBufferData(GL_ARRAY_BUFFER, sizeof(vertices), vertices, GL_STATIC_DRAW);
glEnableVertexAttribArray(position_location);
@@ -136,8 +136,8 @@ TEST_F(PointCoordTest, MAYBE_RenderTo) {
GLfloat s = 0.5 + (xf + 0.5 - xw) / max_point_size;
GLfloat t = 0.5 + (yf + 0.5 - yw) / max_point_size;
uint8 color[4] = {
- s * 255,
- (1 - t) * 255,
+ static_cast<uint8>(s * 255),
+ static_cast<uint8>((1 - t) * 255),
0,
255,
};
diff --git a/net/base/x509_util_nss_unittest.cc b/net/base/x509_util_nss_unittest.cc
index e6c0175..c0dfd42 100644
--- a/net/base/x509_util_nss_unittest.cc
+++ b/net/base/x509_util_nss_unittest.cc
@@ -42,7 +42,7 @@ void VerifyCertificateSignature(const std::string& der_cert,
SECItem der_cert_item = {
siDERCertBuffer,
reinterpret_cast<unsigned char*>(const_cast<char*>(der_cert.data())),
- der_cert.size()
+ static_cast<unsigned int>(der_cert.size())
};
SECStatus rv = SEC_ASN1DecodeItem(arena.get(), &sd,
SEC_ASN1_GET(CERT_SignedDataTemplate),
@@ -85,7 +85,7 @@ void VerifyDomainBoundCert(const std::string& domain,
SECItem extension_object = {
siAsciiString,
(unsigned char*)domain.data(),
- domain.size()
+ static_cast<unsigned int>(domain.size())
};
// IA5Encode and arena allocate SECItem.
diff --git a/net/cookies/cookie_monster_perftest.cc b/net/cookies/cookie_monster_perftest.cc
index 4ccf108..63bd5ac 100644
--- a/net/cookies/cookie_monster_perftest.cc
+++ b/net/cookies/cookie_monster_perftest.cc
@@ -377,8 +377,8 @@ TEST_F(CookieMonsterTest, TestGCTimes) {
const struct TestCase {
const char* name;
- int num_cookies;
- int num_old_cookies;
+ size_t num_cookies;
+ size_t num_old_cookies;
} test_cases[] = {
{
// A whole lot of recent cookies; gc shouldn't happen.
diff --git a/net/cookies/cookie_monster_unittest.cc b/net/cookies/cookie_monster_unittest.cc
index 86cecff..62140cd 100644
--- a/net/cookies/cookie_monster_unittest.cc
+++ b/net/cookies/cookie_monster_unittest.cc
@@ -1725,11 +1725,11 @@ TEST_F(CookieMonsterTest, MAYBE_GarbageCollectionTriggers) {
// time and size of store to make sure we only get rid of cookies when
// we really should.
const struct TestCase {
- int num_cookies;
- int num_old_cookies;
- int expected_initial_cookies;
+ size_t num_cookies;
+ size_t num_old_cookies;
+ size_t expected_initial_cookies;
// Indexed by ExpiryAndKeyScheme
- int expected_cookies_after_set;
+ size_t expected_cookies_after_set;
} test_cases[] = {
{
// A whole lot of recent cookies; gc shouldn't happen.
@@ -1765,13 +1765,11 @@ TEST_F(CookieMonsterTest, MAYBE_GarbageCollectionTriggers) {
CreateMonsterFromStoreForGC(
test_case->num_cookies, test_case->num_old_cookies,
CookieMonster::kSafeFromGlobalPurgeDays * 2));
- EXPECT_EQ(test_case->expected_initial_cookies,
- static_cast<int>(GetAllCookies(cm).size()))
+ EXPECT_EQ(test_case->expected_initial_cookies, GetAllCookies(cm).size())
<< "For test case " << ci;
// Will trigger GC
SetCookie(cm, GURL("http://newdomain.com"), "b=2");
- EXPECT_EQ(test_case->expected_cookies_after_set,
- static_cast<int>((GetAllCookies(cm).size())))
+ EXPECT_EQ(test_case->expected_cookies_after_set, GetAllCookies(cm).size())
<< "For test case " << ci;
}
}
diff --git a/net/spdy/spdy_http_stream_spdy3_unittest.cc b/net/spdy/spdy_http_stream_spdy3_unittest.cc
index f7efe26..1b7760b 100644
--- a/net/spdy/spdy_http_stream_spdy3_unittest.cc
+++ b/net/spdy/spdy_http_stream_spdy3_unittest.cc
@@ -528,8 +528,8 @@ void GetECServerBoundCertAndProof(
// Constructs a standard SPDY SYN_STREAM frame for a GET request with
// a credential set.
-SpdyFrame* ConstructCredentialRequestFrame(int slot, const GURL& url,
- int stream_id) {
+SpdyFrame* ConstructCredentialRequestFrame(size_t slot, const GURL& url,
+ SpdyStreamId stream_id) {
const SpdyHeaderInfo syn_headers = {
SYN_STREAM,
stream_id,
diff --git a/net/spdy/spdy_test_util_spdy2.cc b/net/spdy/spdy_test_util_spdy2.cc
index 5f5e017..179977e 100644
--- a/net/spdy/spdy_test_util_spdy2.cc
+++ b/net/spdy/spdy_test_util_spdy2.cc
@@ -320,13 +320,13 @@ SpdyFrame* ConstructSpdyControlFrame(const char* const extra_headers[],
SpdyFrame* ConstructSpdyControlFrame(const char* const extra_headers[],
int extra_header_count,
bool compressed,
- int stream_id,
+ SpdyStreamId stream_id,
RequestPriority request_priority,
SpdyControlType type,
SpdyControlFlags flags,
const char* const* kHeaders,
int kHeadersSize,
- int associated_stream_id) {
+ SpdyStreamId associated_stream_id) {
const SpdyHeaderInfo kSynStartHeader = {
type, // Kind = Syn
stream_id, // Stream ID
@@ -354,7 +354,7 @@ SpdyFrame* ConstructSpdyControlFrame(const char* const extra_headers[],
// Returns a SpdyFrame.
SpdyFrame* ConstructSpdyGet(const char* const url,
bool compressed,
- int stream_id,
+ SpdyStreamId stream_id,
RequestPriority request_priority) {
const SpdyHeaderInfo kSynStartHeader = {
SYN_STREAM, // Kind = Syn
diff --git a/net/spdy/spdy_test_util_spdy2.h b/net/spdy/spdy_test_util_spdy2.h
index 1a9be94..bc0eb0d 100644
--- a/net/spdy/spdy_test_util_spdy2.h
+++ b/net/spdy/spdy_test_util_spdy2.h
@@ -136,13 +136,13 @@ SpdyFrame* ConstructSpdyControlFrame(const char* const extra_headers[],
SpdyFrame* ConstructSpdyControlFrame(const char* const extra_headers[],
int extra_header_count,
bool compressed,
- int stream_id,
+ SpdyStreamId stream_id,
RequestPriority request_priority,
SpdyControlType type,
SpdyControlFlags flags,
const char* const* kHeaders,
int kHeadersSize,
- int associated_stream_id);
+ SpdyStreamId associated_stream_id);
// Construct an expected SPDY reply string.
// |extra_headers| are the extra header-value pairs, which typically
@@ -199,7 +199,7 @@ int ConstructSpdyHeader(const char* const extra_headers[],
// Returns a SpdyFrame.
SpdyFrame* ConstructSpdyGet(const char* const url,
bool compressed,
- int stream_id,
+ SpdyStreamId stream_id,
RequestPriority request_priority);
// Constructs a standard SPDY GET SYN packet, optionally compressed.
diff --git a/net/spdy/spdy_test_util_spdy3.cc b/net/spdy/spdy_test_util_spdy3.cc
index 79d8100..fc82a32 100644
--- a/net/spdy/spdy_test_util_spdy3.cc
+++ b/net/spdy/spdy_test_util_spdy3.cc
@@ -365,13 +365,13 @@ SpdyFrame* ConstructSpdyControlFrame(const char* const extra_headers[],
SpdyFrame* ConstructSpdyControlFrame(const char* const extra_headers[],
int extra_header_count,
bool compressed,
- int stream_id,
+ SpdyStreamId stream_id,
RequestPriority request_priority,
SpdyControlType type,
SpdyControlFlags flags,
const char* const* kHeaders,
int kHeadersSize,
- int associated_stream_id) {
+ SpdyStreamId associated_stream_id) {
const SpdyHeaderInfo kSynStartHeader = {
type, // Kind = Syn
stream_id, // Stream ID
@@ -400,7 +400,7 @@ SpdyFrame* ConstructSpdyControlFrame(const char* const extra_headers[],
// Returns a SpdyFrame.
SpdyFrame* ConstructSpdyGet(const char* const url,
bool compressed,
- int stream_id,
+ SpdyStreamId stream_id,
RequestPriority request_priority) {
const SpdyHeaderInfo kSynStartHeader = {
SYN_STREAM, // Kind = Syn
diff --git a/net/spdy/spdy_test_util_spdy3.h b/net/spdy/spdy_test_util_spdy3.h
index 5103c89..a3d202b 100644
--- a/net/spdy/spdy_test_util_spdy3.h
+++ b/net/spdy/spdy_test_util_spdy3.h
@@ -176,13 +176,13 @@ SpdyFrame* ConstructSpdyControlFrame(const char* const extra_headers[],
SpdyFrame* ConstructSpdyControlFrame(const char* const extra_headers[],
int extra_header_count,
bool compressed,
- int stream_id,
+ SpdyStreamId stream_id,
RequestPriority request_priority,
SpdyControlType type,
SpdyControlFlags flags,
const char* const* kHeaders,
int kHeadersSize,
- int associated_stream_id);
+ SpdyStreamId associated_stream_id);
// Construct an expected SPDY reply string.
// |extra_headers| are the extra header-value pairs, which typically
@@ -239,7 +239,7 @@ int ConstructSpdyHeader(const char* const extra_headers[],
// Returns a SpdyFrame.
SpdyFrame* ConstructSpdyGet(const char* const url,
bool compressed,
- int stream_id,
+ SpdyStreamId stream_id,
RequestPriority request_priority);
// Constructs a standard SPDY GET SYN packet, optionally compressed.
diff --git a/sync/internal_api/sync_encryption_handler_impl_unittest.cc b/sync/internal_api/sync_encryption_handler_impl_unittest.cc
index 872e423..6e0b757 100644
--- a/sync/internal_api/sync_encryption_handler_impl_unittest.cc
+++ b/sync/internal_api/sync_encryption_handler_impl_unittest.cc
@@ -1311,7 +1311,6 @@ TEST_F(SyncEncryptionHandlerImplTest, ReceiveOldMigratedNigori) {
sync_pb::EncryptedData encrypted;
KeyParams old_key = {"localhost", "dummy", kOldKey};
KeyParams cur_key = {"localhost", "dummy", kCurKey};
- KeyParams keystore_key = {"localhost", "dummy", kKeystoreKey};
GetCryptographer()->AddKey(old_key);
GetCryptographer()->AddKey(cur_key);
@@ -1874,7 +1873,6 @@ TEST_F(SyncEncryptionHandlerImplTest,
sync_pb::EncryptedData encrypted;
KeyParams old_key = {"localhost", "dummy", kOldKey};
KeyParams cur_key = {"localhost", "dummy", kCurKey};
- KeyParams keystore_key = {"localhost", "dummy", kKeystoreKey};
GetCryptographer()->AddKey(old_key);
GetCryptographer()->AddKey(cur_key);