X-Git-Url: https://tinc-vpn.org/git/browse?a=blobdiff_plain;f=src%2Fsptps.c;h=4a9683f29aed3076de37f9051ab34eb50fbe35d9;hb=c46bdbde18629f0a0613c776c13a79fea0ec6093;hp=a5987682695b76c04b2761b5b496c73ad6779f6d;hpb=107d9c7da5b206425a8e1643a6849ea990f725f8;p=tinc diff --git a/src/sptps.c b/src/sptps.c index a5987682..4a9683f2 100644 --- a/src/sptps.c +++ b/src/sptps.c @@ -483,10 +483,10 @@ static bool sptps_receive_data_datagram(sptps_t *s, const char *data, size_t len if(!s->instate) return error(s, EIO, "Application record received before handshake finished"); if(!s->receive_record(s->handle, type, buffer + 1, len - 21)) - abort(); + return false; } else if(type == SPTPS_HANDSHAKE) { if(!receive_handshake(s, buffer + 1, len - 21)) - abort(); + return false; } else { return error(s, EIO, "Invalid record type %d", type); }