From 3d23215e95a3e737376fcf4c9ec154551874a636 Mon Sep 17 00:00:00 2001 From: David Renshaw Date: Mon, 2 Sep 2024 13:55:18 -0400 Subject: [PATCH] tighter size_hint estimate for Resolve --- capnp-rpc/src/rpc.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/capnp-rpc/src/rpc.rs b/capnp-rpc/src/rpc.rs index 27f3f9ca3..d0d60ccb2 100644 --- a/capnp-rpc/src/rpc.rs +++ b/capnp-rpc/src/rpc.rs @@ -1331,7 +1331,7 @@ impl ConnectionState { } // OK, we have to send a `Resolve` message. - let mut message = connection_state.new_outgoing_message(100)?; // XXX size hint? + let mut message = connection_state.new_outgoing_message(15)?; { let root: message::Builder = message.get_body()?.get_as()?; let mut resolve = root.init_resolve(); @@ -1347,7 +1347,7 @@ impl ConnectionState { } Err(e) => { // send error resolution - let mut message = connection_state.new_outgoing_message(100)?; // XXX size hint? + let mut message = connection_state.new_outgoing_message(15)?; { let root: message::Builder = message.get_body()?.get_as()?; let mut resolve = root.init_resolve();