From e99e6a478eebfac7b94f5b9f7bb612e44751dc61 Mon Sep 17 00:00:00 2001 From: chimp1984 Date: Sun, 6 Sep 2020 20:18:50 -0500 Subject: [PATCH] Add InvalidProtocolBufferException in catch clause --- p2p/src/main/java/bisq/network/p2p/network/Connection.java | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/p2p/src/main/java/bisq/network/p2p/network/Connection.java b/p2p/src/main/java/bisq/network/p2p/network/Connection.java index 436e3d51a4..86aa7d4fc7 100644 --- a/p2p/src/main/java/bisq/network/p2p/network/Connection.java +++ b/p2p/src/main/java/bisq/network/p2p/network/Connection.java @@ -48,6 +48,8 @@ import bisq.common.proto.network.NetworkEnvelope; import bisq.common.proto.network.NetworkProtoResolver; import bisq.common.util.Utilities; +import com.google.protobuf.InvalidProtocolBufferException; + import javax.inject.Inject; import com.google.common.util.concurrent.MoreExecutors; @@ -884,7 +886,7 @@ public class Connection implements HasCapabilities, Runnable, MessageListener { log.error(e.getMessage()); e.printStackTrace(); reportInvalidRequest(RuleViolation.INVALID_CLASS); - } catch (ProtobufferException | NoClassDefFoundError e) { + } catch (ProtobufferException | NoClassDefFoundError | InvalidProtocolBufferException e) { log.error(e.getMessage()); e.printStackTrace(); reportInvalidRequest(RuleViolation.INVALID_DATA_TYPE);