diff options
Diffstat (limited to 'src/ipcpd')
| -rw-r--r-- | src/ipcpd/broadcast/enroll.c | 6 | ||||
| -rw-r--r-- | src/ipcpd/unicast/enroll.c | 6 | 
2 files changed, 6 insertions, 6 deletions
diff --git a/src/ipcpd/broadcast/enroll.c b/src/ipcpd/broadcast/enroll.c index 36b82af1..511892b7 100644 --- a/src/ipcpd/broadcast/enroll.c +++ b/src/ipcpd/broadcast/enroll.c @@ -87,7 +87,7 @@ static int send_rcv_enroll_msg(int fd)          clock_gettime(CLOCK_REALTIME, &t0); -        if (flow_write(fd, buf, len)) { +        if (flow_write(fd, buf, len) < 0) {                  log_dbg("Failed to send request message.");                  return -1;          } @@ -222,7 +222,7 @@ static void * enroll_handle(void * o)                  log_dbg("Sending enrollment info (%zd bytes).", len); -                if (flow_write(conn.flow_info.fd, reply, len)) { +                if (flow_write(conn.flow_info.fd, reply, len) < 0) {                          log_err("Failed respond to enrollment request.");                          connmgr_dealloc(COMPID_ENROLL, &conn);                          free(reply); @@ -296,7 +296,7 @@ int enroll_done(struct conn * conn,          enroll_msg__pack(&msg, buf); -        if (flow_write(conn->flow_info.fd, buf, len)) { +        if (flow_write(conn->flow_info.fd, buf, len) < 0) {                  log_dbg("Failed to send acknowledgment.");                  return -1;          } diff --git a/src/ipcpd/unicast/enroll.c b/src/ipcpd/unicast/enroll.c index 6a612ff3..3b4a5a89 100644 --- a/src/ipcpd/unicast/enroll.c +++ b/src/ipcpd/unicast/enroll.c @@ -87,7 +87,7 @@ static int send_rcv_enroll_msg(int fd)          clock_gettime(CLOCK_REALTIME, &t0); -        if (flow_write(fd, buf, len)) { +        if (flow_write(fd, buf, len) < 0) {                  log_dbg("Failed to send request message.");                  return -1;          } @@ -238,7 +238,7 @@ static void * enroll_handle(void * o)                  log_dbg("Sending enrollment info (%zd bytes).", len); -                if (flow_write(conn.flow_info.fd, reply, len)) { +                if (flow_write(conn.flow_info.fd, reply, len) < 0) {                          log_err("Failed respond to enrollment request.");                          connmgr_dealloc(COMPID_ENROLL, &conn);                          free(reply); @@ -312,7 +312,7 @@ int enroll_done(struct conn * conn,          enroll_msg__pack(&msg, buf); -        if (flow_write(conn->flow_info.fd, buf, len)) { +        if (flow_write(conn->flow_info.fd, buf, len) < 0) {                  log_dbg("Failed to send acknowledgment.");                  return -1;          }  | 
