]> tinc-vpn.org Git - tinc/blobdiff - src/linux/device.c
doc: there is, not their is
[tinc] / src / linux / device.c
index a06e6daf9a6f909b136528f889741a8a495d0558..e273bfaeada736ac965bdc8c34b7051f5de2ca26 100644 (file)
@@ -139,6 +139,9 @@ static bool read_packet(vpn_packet_t *packet) {
                        if(inlen <= 0) {
                                logger(DEBUG_ALWAYS, LOG_ERR, "Error while reading from %s %s: %s",
                                           device_info, device, strerror(errno));
+                               if (errno == EBADFD) { /* File descriptor in bad state */
+                                       event_exit();
+                               }
                                return false;
                        }