diff --git a/rpc/rpc_impl.hh b/rpc/rpc_impl.hh index e373f066b5..c44781db31 100644 --- a/rpc/rpc_impl.hh +++ b/rpc/rpc_impl.hh @@ -29,8 +29,8 @@ namespace rpc { template -inline std::enable_if_t> marshall(Serializer&, output_stream&, std::tuple&&) { - return make_ready_future<>(); +inline std::enable_if_t> marshall(Serializer&, output_stream& out, std::tuple&&) { + return out.flush(); } template @@ -38,8 +38,6 @@ inline std::enable_if_t> marshall(Serializer& serial using tuple_type = std::tuple; return serialize(out, std::forward::type>(std::get(args))).then([&serialize, &out, args = std::move(args)] () mutable { return marshall(serialize, out, std::move(args)); - }).then([&out] { - return out.flush(); }); }