.TH LC_CHANNEL_SEND 3 2023-08-09 "LIBRECAST" "Librecast Programmer's Manual" .SH NAME lc_channel_send, lc_channel_sendmsg \- send data on a Librecast channel .SH LIBRARY Librecast library .RI ( liblibrecast ", " \-llibrecast ) .SH SYNOPSIS .nf .B #include .PP .BI "ssize_t lc_channel_send(lc_channel_t "*chan ", const void " *buf ", size_t " len ", int " flags ")" .BI "ssize_t lc_channel_sendmsg(lc_channel_t " *chan ", struct msghdr " *msg ", int " flags ");" .fi .PP Compile and link with \fI\-llibrecast\fP. .SH DESCRIPTION Each of these functions sends data over multicast on the librecast channel .IR chan . They are analogous to the .BR send (2) and .BR sendmsg (2) calls. .PP In addition to the usual flags used with .BR send (2) and .BR sendmsg (2) these functions support the following flags: .TP .BR MSG_DROP This flag causes the packet to be dropped instead of sending. It is used for testing. All normal processing, such as encoding proceeds as usual. Only the final send syscall is skipped. The return value will be the number of bytes that would have been sent. .SH RETURN VALUE These calls return the number of bytes received, or -1 if an error occurred. In the event of an error, .I errno is set to indicate the error. .SH ERRORS See .BR send (2). .SH SEE ALSO .BR lc_ctx_new(3), .BR lc_channel_new (3), .BR send (2), .BR sendmsg (2)