From 542897ce2ed7fb8a8627ec8ba8b3490acb29149f Mon Sep 17 00:00:00 2001 From: hozan23 Date: Tue, 21 Nov 2023 15:38:45 +0300 Subject: jsonrpc: switch to LF delimiter for reading json, replacing the dummy delimiter --- jsonrpc/src/client.rs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'jsonrpc/src/client.rs') diff --git a/jsonrpc/src/client.rs b/jsonrpc/src/client.rs index 1ce9ecb..f5277aa 100644 --- a/jsonrpc/src/client.rs +++ b/jsonrpc/src/client.rs @@ -58,7 +58,8 @@ impl Client { params: serde_json::json!(params), }; - let payload = serde_json::to_vec(&request)?; + let mut payload = serde_json::to_vec(&request)?; + payload.push(b'\n'); self.codec.write_all(&payload).await?; debug!("--> {request}"); -- cgit v1.2.3