Skip to content

Commit 46b4092

Browse files
committed
Check fr_network_sendto_worker return code
1 parent b84ce33 commit 46b4092

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/listen/bfd/session.c

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -797,7 +797,10 @@ static void bfd_unlang_send_packet(UNUSED fr_event_list_t *el, UNUSED fr_time_t
797797
&session->client.src_ipaddr, session->port);
798798
if (!track) return;
799799

800-
(void) fr_network_sendto_worker(session->nr, parent, track, (uint8_t const *) wrapper, (wrapper->packet + bfd->length) - (uint8_t *) wrapper, fr_time());
800+
if (unlikely(fr_network_sendto_worker(session->nr, parent, track, (uint8_t const *) wrapper,
801+
(wrapper->packet + bfd->length) - (uint8_t *) wrapper, fr_time()) < 0)) {
802+
PERROR("Failed sending packet to worker");
803+
};
801804
}
802805

803806
/*

0 commit comments

Comments
 (0)