Cancel threads to ensure they abort blocking I/O operations.
[tinc] / src / net_packet.c
index 61a9f48..269f314 100644 (file)
@@ -589,11 +589,8 @@ void handle_incoming_vpn_data(void *arg) {
                len = recvfrom(l->udp, (char *) &pkt.seqno, MAXSIZE, 0, &from.sa, &fromlen);
 
                if(len <= 0 || len > MAXSIZE) {
-                       if(!sockwouldblock(sockerrno)) {
-                               logger(LOG_ERR, "Receiving packet failed: %s", sockstrerror(sockerrno));
-                               return;
-                       }
-                       continue;
+                       logger(LOG_ERR, "Receiving packet failed: %s", sockstrerror(sockerrno));
+                       return;
                }
 
                pkt.len = len;