libosmocore UNKNOWN
Osmocom core library
Loading...
Searching...
No Matches
osmo_io_ops::[struct].__unnamed2__ Struct Reference

Data Fields

void(*) recvmsg_cb (struct osmo_io_fd *iofd, int res, struct msgb *msg, const struct msghdr *msgh)
 completion call-back function when recvmsg(2) has completed.
void(*) sendmsg_cb (struct osmo_io_fd *iofd, int res, struct msgb *msg)
 completion call-back function when sendmsg() issued via osmo_iofd_sendmsg_msgb() has completed on fd.

Field Documentation

◆ recvmsg_cb

void(*) osmo_io_ops::[struct].__unnamed2__(struct osmo_io_fd *iofd, int res, struct msgb *msg, const struct msghdr *msgh)

completion call-back function when recvmsg(2) has completed.

Only valid in OSMO_IO_FD_MODE_RECVMSG_SENDMSG.

Parameters
[in]iofdosmo_io_fd for which recvmsg() has completed.
[in]resreturn value of the recvmsg() call, or -errno in case of error.
[in]msgmessage buffer containing the read data. Ownership is transferred to the call-back, and it must make sure to msgb_free() it eventually!
[in]msghmsghdr containing metadata related to the recvmsg call. Only valid until call-back ends.

◆ sendmsg_cb

void(*) osmo_io_ops::[struct].__unnamed2__(struct osmo_io_fd *iofd, int res, struct msgb *msg)

completion call-back function when sendmsg() issued via osmo_iofd_sendmsg_msgb() has completed on fd.

Only valid in Only valid in OSMO_IO_FD_MODE_RECVMSG_SENDMSG.

Parameters
[in]iofdon which a sendmsg() has completed.
[in]resreturn value of the sendmsg() call, or -errno in case of error.
[in]msgmessage buffer whose write has completed. Ownership is not transferred to the call-back; it is automatically freed after the call-back terminates!

The documentation for this struct was generated from the following files: