aboutsummaryrefslogtreecommitdiffhomepage
path: root/test/cpp/qps
diff options
context:
space:
mode:
authorGravatar Vijay Pai <vpai@google.com>2017-07-18 10:42:33 -0700
committerGravatar Vijay Pai <vpai@google.com>2017-07-18 11:07:43 -0700
commit0f95fa4909ba6f65364cb0b5c8c37a27c09b67b4 (patch)
treea98b582aa9e26d6aca4a3e23e8a4ab9dfe883ec3 /test/cpp/qps
parentc39d4c16a02d49a1e4b090309786643045287639 (diff)
Add idiomatic C++ API for grpc::Slice construction that doesn't
require using grpc_slice
Diffstat (limited to 'test/cpp/qps')
-rw-r--r--test/cpp/qps/client.h4
1 files changed, 1 insertions, 3 deletions
diff --git a/test/cpp/qps/client.h b/test/cpp/qps/client.h
index e759446c1a..ecbf9c31fa 100644
--- a/test/cpp/qps/client.h
+++ b/test/cpp/qps/client.h
@@ -88,9 +88,7 @@ class ClientRequestCreator<ByteBuffer> {
if (payload_config.has_bytebuf_params()) {
std::unique_ptr<char[]> buf(
new char[payload_config.bytebuf_params().req_size()]);
- grpc_slice s = grpc_slice_from_copied_buffer(
- buf.get(), payload_config.bytebuf_params().req_size());
- Slice slice(s, Slice::STEAL_REF);
+ Slice slice(buf.get(), payload_config.bytebuf_params().req_size());
*req = ByteBuffer(&slice, 1);
} else {
GPR_ASSERT(false); // not appropriate for this specialization