Skip to content
Snippets Groups Projects
Commit b30bc2aa authored by Vijay Pai's avatar Vijay Pai
Browse files

Remove dead code and a thus unneeded change to C++ bbuf

parent 60456810
No related branches found
No related tags found
No related merge requests found
......@@ -72,9 +72,6 @@ class ByteBuffer GRPC_FINAL {
/// Buffer size in bytes.
size_t Length() const;
/// Move contents from \a bbuf and clear \a bbuf
void MoveFrom(ByteBuffer* bbuf);
private:
friend class SerializationTraits<ByteBuffer, void>;
......
......@@ -79,12 +79,6 @@ size_t ByteBuffer::Length() const {
}
}
void ByteBuffer::MoveFrom(ByteBuffer* bbuf) {
Clear(); // in case we already had something, but we shouldn't use this then
buffer_ = bbuf->buffer_;
bbuf->buffer_ = nullptr;
}
ByteBuffer::ByteBuffer(const ByteBuffer& buf):
buffer_(grpc_byte_buffer_copy(buf.buffer_)) {
}
......
......@@ -118,8 +118,6 @@ class ClientRequestCreator<ByteBuffer> {
buf.get(), payload_config.bytebuf_params().req_size());
Slice slice(s, Slice::STEAL_REF);
*req = ByteBuffer(&slice, 1);
// std::unique_ptr<ByteBuffer> bbuf(new ByteBuffer(&slice, 1));
// req->MoveFrom(bbuf.get());
} else {
GPR_ASSERT(false); // not appropriate for this specialization
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment