aboutsummaryrefslogtreecommitdiff
path: root/shard/lib/net
diff options
context:
space:
mode:
Diffstat (limited to 'shard/lib/net')
-rw-r--r--shard/lib/net/tcpconn.ex4
1 files changed, 4 insertions, 0 deletions
diff --git a/shard/lib/net/tcpconn.ex b/shard/lib/net/tcpconn.ex
index 44669bb..35f7ea5 100644
--- a/shard/lib/net/tcpconn.ex
+++ b/shard/lib/net/tcpconn.ex
@@ -43,6 +43,10 @@ defmodule SNet.TCPConn do
len = byte_size(expected_suffix)
^len = :binary.longest_common_suffix([cli_pkey, expected_suffix])
+ if srv_pkey == cli_pkey do
+ exit :normal
+ end
+
# Connected
:inet.setopts(socket, [active: true])