diff options
author | Jan Tattermusch <jtattermusch@users.noreply.github.com> | 2018-01-26 08:52:42 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-01-26 08:52:42 +0100 |
commit | 8f4082799086a098fa6aaa20320bdc5b4fed40f3 (patch) | |
tree | 4847adf903def87dce553db4e54bab973f93fd18 /test/core | |
parent | e0adbb6c2e714b06dfa42becae97dfe5ae79d2cb (diff) | |
parent | 2f090e9732c1bc6194e7d6e55d27eb03142c172e (diff) |
Merge pull request #14136 from jtattermusch/add_ubuntu_1710
Fix build under gcc7.2
Diffstat (limited to 'test/core')
-rw-r--r-- | test/core/memory_usage/server.cc | 1 | ||||
-rw-r--r-- | test/core/surface/byte_buffer_reader_test.cc | 8 |
2 files changed, 5 insertions, 4 deletions
diff --git a/test/core/memory_usage/server.cc b/test/core/memory_usage/server.cc index 60ebcece3e..45aeaea661 100644 --- a/test/core/memory_usage/server.cc +++ b/test/core/memory_usage/server.cc @@ -289,6 +289,7 @@ int main(int argc, char** argv) { } // no break here since we want to continue to case // FLING_SERVER_SEND_STATUS_SNAPSHOT to destroy the snapshot call + /* fallthrough */ case FLING_SERVER_SEND_STATUS_SNAPSHOT: grpc_byte_buffer_destroy(payload_buffer); grpc_byte_buffer_destroy(terminal_buffer); diff --git a/test/core/surface/byte_buffer_reader_test.cc b/test/core/surface/byte_buffer_reader_test.cc index 0c8a07c7fd..91662b027a 100644 --- a/test/core/surface/byte_buffer_reader_test.cc +++ b/test/core/surface/byte_buffer_reader_test.cc @@ -205,8 +205,8 @@ static void test_readall(void) { LOG_TEST("test_readall"); - memset(lotsa_as, 'a', 512); - memset(lotsa_bs, 'b', 1024); + memset(lotsa_as, 'a', 512 * sizeof(lotsa_as[0])); + memset(lotsa_bs, 'b', 1024 * sizeof(lotsa_bs[0])); /* use slices large enough to overflow inlining */ slices[0] = grpc_slice_malloc(512); memcpy(GRPC_SLICE_START_PTR(slices[0]), lotsa_as, 512); @@ -240,8 +240,8 @@ static void test_byte_buffer_copy(void) { LOG_TEST("test_byte_buffer_copy"); - memset(lotsa_as, 'a', 512); - memset(lotsa_bs, 'b', 1024); + memset(lotsa_as, 'a', 512 * sizeof(lotsa_as[0])); + memset(lotsa_bs, 'b', 1024 * sizeof(lotsa_bs[0])); /* use slices large enough to overflow inlining */ slices[0] = grpc_slice_malloc(512); memcpy(GRPC_SLICE_START_PTR(slices[0]), lotsa_as, 512); |