From c03be059f5b2655e1c2307a676421ec26d91ae76 Mon Sep 17 00:00:00 2001 From: "Nicholas J. Kain" Date: Sun, 6 Apr 2014 06:31:40 -0400 Subject: [PATCH] writeordie() was buggy; delete the == 1 which makes no sense. --- ndhc/ifchd.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ndhc/ifchd.c b/ndhc/ifchd.c index cc7e88d..6b1a79c 100644 --- a/ndhc/ifchd.c +++ b/ndhc/ifchd.c @@ -71,7 +71,7 @@ gid_t ifch_gid = 0; static void writeordie(int fd, const char *buf, size_t len) { - ssize_t r = safe_write(fd, buf, len) == -1; + ssize_t r = safe_write(fd, buf, len); if (r < 0 || (size_t)r != len) suicide("%s: (%s) write failed: %d", client_config.interface, __func__, r);