From dda980968319490074e5315d48f2ba51fc8b9e29 Mon Sep 17 00:00:00 2001 From: Matthias Schiffer Date: Sat, 20 Apr 2013 20:03:47 +0200 Subject: ec25519-fhmqvc: drop is_established test in protocol_handle_recv() handle_socket() now tests it before calling handle_recv --- src/protocol_ec25519_fhmqvc.c | 7 ------- 1 file changed, 7 deletions(-) (limited to 'src') diff --git a/src/protocol_ec25519_fhmqvc.c b/src/protocol_ec25519_fhmqvc.c index 662f3b8..1f58ae3 100644 --- a/src/protocol_ec25519_fhmqvc.c +++ b/src/protocol_ec25519_fhmqvc.c @@ -781,13 +781,6 @@ static void protocol_handshake_handle(fastd_context_t *ctx, fastd_socket_t *sock } static void protocol_handle_recv(fastd_context_t *ctx, fastd_peer_t *peer, fastd_buffer_t buffer) { - if (!fastd_peer_is_established(peer)) { - pr_debug(ctx, "received unexpected packet from %P, scheduling handshake", peer); - fastd_task_schedule_handshake(ctx, peer, 0); - - goto fail; - } - if (!peer->protocol_state || !is_session_valid(ctx, &peer->protocol_state->session)) goto fail; -- cgit v1.2.3