Commit bc2858ad authored by Robert Lubos's avatar Robert Lubos Committed by Henrik Brix Andersen
Browse files

net: lib: coap: Add error check when waking server thread



There's not much to be done in case waking up the server thread with
socketpair send() fails, but at least we can log an error on such event
(to please coverity).

Signed-off-by: default avatarRobert Lubos <robert.lubos@nordicsemi.no>
parent b2b40169
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
@@ -335,7 +335,9 @@ static int coap_server_poll_timeout(void)

static void coap_server_update_services(void)
{
	zsock_send(control_socks[1], &(char){0}, 1, 0);
	if (zsock_send(control_socks[1], &(char){0}, 1, 0) < 0) {
		LOG_ERR("Failed to notify server thread (%d)", errno);
	}
}

static inline bool coap_service_in_section(const struct coap_service *service)