From 07c5482e30e90e1a5200992ca30ea6c4d1e4efbc Mon Sep 17 00:00:00 2001 From: Radoslaw Zarzynski Date: Thu, 14 Feb 2019 20:31:49 +0100 Subject: [PATCH] msg/async: rectify reseting security state in ProtocolV2::reset_recv_state(). The reason for that is: 2019-02-14 19:59:00.774 7f78aebf3700 20 --2- v2:127.0.0.1:40678/0 >> v2:127.0.0.1:40680/0 conn(0x5574ae75e480 0x5574ae696000 :-1 s=READY pgs=11 cs=0 l=0 rx=0x5574ae2af5f0 tx=0x5574ae79bc00).handle_read_frame_preamble_main r=-1 2019-02-14 19:59:00.774 7f78aebf3700 1 --2- v2:127.0.0.1:40678/0 >> v2:127.0.0.1:40680/0 conn(0x5574ae75e480 0x5574ae696000 :-1 s=READY pgs=11 cs=0 l=0 rx=0x5574ae2af5f0 tx=0x5574ae79bc00).handle_read_frame_preamble_main read frame length and tag failed r=-1 ((1) Operation not permitted) 2019-02-14 19:59:00.774 7f78aebf3700 10 --2- v2:127.0.0.1:40678/0 >> v2:127.0.0.1:40680/0 conn(0x5574ae75e480 0x5574ae696000 :-1 s=READY pgs=11 cs=0 l=0 rx=0x5574ae2af5f0 tx=0x5574ae79bc00)._fault Signed-off-by: Radoslaw Zarzynski --- src/msg/async/ProtocolV2.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/msg/async/ProtocolV2.cc b/src/msg/async/ProtocolV2.cc index 48a1d7d852e..c0f17ddb2d7 100644 --- a/src/msg/async/ProtocolV2.cc +++ b/src/msg/async/ProtocolV2.cc @@ -700,7 +700,7 @@ uint64_t ProtocolV2::discard_requeued_up_to(uint64_t out_seq, uint64_t seq) { } void ProtocolV2::reset_recv_state() { - if (state == CONNECTING) { + if (state == CONNECTING || state == READY) { auth_meta.reset(new AuthConnectionMeta); session_stream_handlers.tx.reset(nullptr); session_stream_handlers.rx.reset(nullptr); -- 2.39.5