]> git.ipfire.org Git - thirdparty/dhcpcd.git/commitdiff
control: Ingore control not connected errors too
authorRoy Marples <roy@marples.name>
Wed, 17 May 2023 09:52:23 +0000 (10:52 +0100)
committerRoy Marples <roy@marples.name>
Wed, 17 May 2023 09:52:23 +0000 (10:52 +0100)
For FreeBSD.
Another one for #205.

src/control.c

index 8c6306907a8cebda3c1d7aab3abe7f5bb053784e..3de8bf91f92d8b140b079949f67f843cbded238b 100644 (file)
@@ -164,8 +164,10 @@ control_handle_write(struct fd_list *fd)
        }
 
        if (writev(fd->fd, iov, iov_len) == -1) {
-               if (errno != EPIPE) // We don't get ELE_HANGUP for some reason
+               if (errno != EPIPE && errno != ENOTCONN) {
+                       // We don't get ELE_HANGUP for some reason
                        logerr("%s: write", __func__);
+               }
                control_hangup(fd);
                return;
        }