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

Issue 759063003: Fix "value possibly truncated" warnings on MSVC, net/spdy/ edition. (Closed)

Created:
6 years ago by Peter Kasting
Modified:
6 years ago
Reviewers:
Bence, Ryan Hamilton
CC:
chromium-reviews, cbentzel+watch_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Project:
chromium
Visibility:
Public.

Description

Fix "value possibly truncated" warnings on MSVC, net/spdy/ edition. Specifically, this addresses some instances of C4244 ( http://msdn.microsoft.com/en-us/library/th7a07tz.aspx ). Also does a few misc. cleanups, mostly to test code. Note: This CL includes server-side change 81444427. BUG=81439 TEST=none Committed: https://crrev.com/1662810517ea5b08e4e334b3eb9450833c148fb6 Cr-Commit-Position: refs/heads/master@{#307099}

Patch Set 1 #

Patch Set 2 : Test tweaks #

Total comments: 19

Patch Set 3 : Review comments #

Patch Set 4 : Fix compile #

Patch Set 5 : Fix stupid code #

Patch Set 6 : I cn code gud #

Patch Set 7 : Review comments #

Total comments: 2

Patch Set 8 : Reintroduce using directive #

Total comments: 2

Patch Set 9 : Review comment #

Unified diffs Side-by-side diffs Delta from patch set Stats (+121 lines, -115 lines) Patch
M net/spdy/buffered_spdy_framer.h View 1 chunk +1 line, -1 line 0 comments Download
M net/spdy/buffered_spdy_framer.cc View 1 chunk +1 line, -1 line 0 comments Download
M net/spdy/fuzzing/hpack_fuzz_util.cc View 1 chunk +2 lines, -1 line 0 comments Download
M net/spdy/hpack_huffman_table.h View 1 2 1 chunk +2 lines, -1 line 0 comments Download
M net/spdy/hpack_huffman_table.cc View 1 2 2 chunks +3 lines, -1 line 0 comments Download
M net/spdy/hpack_huffman_table_test.cc View 1 2 1 chunk +6 lines, -12 lines 0 comments Download
M net/spdy/spdy_frame_builder.h View 1 chunk +1 line, -1 line 0 comments Download
M net/spdy/spdy_framer.h View 1 chunk +1 line, -1 line 0 comments Download
M net/spdy/spdy_framer.cc View 1 2 3 4 5 6 7 8 14 chunks +25 lines, -24 lines 0 comments Download
M net/spdy/spdy_framer_test.cc View 1 2 3 4 5 6 7 35 chunks +71 lines, -61 lines 0 comments Download
M net/spdy/spdy_protocol.h View 1 2 3 4 5 6 2 chunks +3 lines, -6 lines 0 comments Download
M net/spdy/spdy_session.h View 1 2 3 3 chunks +3 lines, -3 lines 0 comments Download
M net/spdy/spdy_session.cc View 1 2 3 2 chunks +2 lines, -2 lines 0 comments Download

Messages

Total messages: 21 (3 generated)
Peter Kasting
https://codereview.chromium.org/759063003/diff/20001/net/spdy/hpack_huffman_table_test.cc File net/spdy/hpack_huffman_table_test.cc (right): https://codereview.chromium.org/759063003/diff/20001/net/spdy/hpack_huffman_table_test.cc#newcode241 net/spdy/hpack_huffman_table_test.cc:241: EXPECT_EQ(arraysize(code), peer_.code_by_id().size()); This is a more compact and future-proof ...
6 years ago (2014-11-25 22:51:01 UTC) #2
Ryan Hamilton
I'm going to hand this off to bnc@ since it includes changes to code that ...
6 years ago (2014-11-27 17:00:06 UTC) #4
Bence
Peter: nits. I did a preliminary upstreaming to internal code, and tests pass there too. ...
6 years ago (2014-12-01 18:18:38 UTC) #5
Peter Kasting
PTAL. https://codereview.chromium.org/759063003/diff/20001/net/spdy/hpack_huffman_table.cc File net/spdy/hpack_huffman_table.cc (right): https://codereview.chromium.org/759063003/diff/20001/net/spdy/hpack_huffman_table.cc#newcode60 net/spdy/hpack_huffman_table.cc:60: return false; On 2014/12/01 18:18:38, Bence wrote: > ...
6 years ago (2014-12-02 02:13:56 UTC) #6
Bence
Peter: just one more thing please. https://codereview.chromium.org/759063003/diff/20001/net/spdy/hpack_huffman_table_test.cc File net/spdy/hpack_huffman_table_test.cc (right): https://codereview.chromium.org/759063003/diff/20001/net/spdy/hpack_huffman_table_test.cc#newcode241 net/spdy/hpack_huffman_table_test.cc:241: EXPECT_EQ(arraysize(code), peer_.code_by_id().size()); On ...
6 years ago (2014-12-02 14:58:44 UTC) #7
Bence
Please link to https://crbug.com/438263 in the TODO(bnc) comment if you have not had a chance ...
6 years ago (2014-12-02 17:28:00 UTC) #8
Peter Kasting
https://codereview.chromium.org/759063003/diff/20001/net/spdy/spdy_framer.cc File net/spdy/spdy_framer.cc (right): https://codereview.chromium.org/759063003/diff/20001/net/spdy/spdy_framer.cc#newcode2860 net/spdy/spdy_framer.cc:2860: builder.WriteUInt8(static_cast<uint8>(altsvc.protocol_id().length())); On 2014/12/02 14:58:44, Bence wrote: > On 2014/12/02 ...
6 years ago (2014-12-03 00:27:08 UTC) #9
Bence
Peter: this looks fine to me, but please give me some time to work on ...
6 years ago (2014-12-03 22:48:24 UTC) #10
Bence
Peter: unfortunately there is one issue that needs remedy. https://codereview.chromium.org/759063003/diff/120001/net/spdy/spdy_framer_test.cc File net/spdy/spdy_framer_test.cc (left): https://codereview.chromium.org/759063003/diff/120001/net/spdy/spdy_framer_test.cc#oldcode22 net/spdy/spdy_framer_test.cc:22: ...
6 years ago (2014-12-03 23:23:21 UTC) #11
Peter Kasting
https://codereview.chromium.org/759063003/diff/120001/net/spdy/spdy_framer_test.cc File net/spdy/spdy_framer_test.cc (left): https://codereview.chromium.org/759063003/diff/120001/net/spdy/spdy_framer_test.cc#oldcode22 net/spdy/spdy_framer_test.cc:22: using std::string; On 2014/12/03 23:23:20, Bence wrote: > Could ...
6 years ago (2014-12-03 23:33:13 UTC) #12
Peter Kasting
Reverted "using std::string" deletion. I also changed one other member in this file that was ...
6 years ago (2014-12-05 03:48:44 UTC) #13
Bence
Peter: one more nit. Thanks. https://codereview.chromium.org/759063003/diff/140001/net/spdy/spdy_framer.cc File net/spdy/spdy_framer.cc (right): https://codereview.chromium.org/759063003/diff/140001/net/spdy/spdy_framer.cc#newcode747 net/spdy/spdy_framer.cc:747: ((protocol_version() > SPDY3) ? ...
6 years ago (2014-12-05 17:22:01 UTC) #14
Peter Kasting
If you have only nits and are OK with a change landing after they're addressed, ...
6 years ago (2014-12-05 19:21:28 UTC) #15
Bence
On 2014/12/05 19:21:28, Peter Kasting wrote: > If you have only nits and are OK ...
6 years ago (2014-12-05 21:00:02 UTC) #16
Ryan Hamilton
sorry for the delay. lgtm
6 years ago (2014-12-05 21:47:01 UTC) #17
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/759063003/160001
6 years ago (2014-12-05 21:50:09 UTC) #19
commit-bot: I haz the power
Committed patchset #9 (id:160001)
6 years ago (2014-12-05 22:49:51 UTC) #20
commit-bot: I haz the power
6 years ago (2014-12-05 22:50:42 UTC) #21
Message was sent while issue was closed.
Patchset 9 (id:??) landed as
https://crrev.com/1662810517ea5b08e4e334b3eb9450833c148fb6
Cr-Commit-Position: refs/heads/master@{#307099}

Powered by Google App Engine
This is Rietveld 408576698