diff options
author | Luke T. Shumaker <lukeshu@lukeshu.com> | 2024-11-04 12:49:09 -0700 |
---|---|---|
committer | Luke T. Shumaker <lukeshu@lukeshu.com> | 2024-11-10 22:07:33 -0700 |
commit | 1e8897a61addec5c2067ffbab38122d6c236ced3 (patch) | |
tree | 0e81b9b4d07fa8a3394ccadee919b79e059ba19e /libhw/common_include | |
parent | 3c81186daf97cf7011fd2806dfd0bc3b875e92f3 (diff) |
libhw: net.h: Clarify UDP truncation behavior
Diffstat (limited to 'libhw/common_include')
-rw-r--r-- | libhw/common_include/libhw/generic/net.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/libhw/common_include/libhw/generic/net.h b/libhw/common_include/libhw/generic/net.h index 8dedaea..e23dcda 100644 --- a/libhw/common_include/libhw/generic/net.h +++ b/libhw/common_include/libhw/generic/net.h @@ -106,6 +106,11 @@ struct net_packet_conn_vtable { ssize_t (*sendto )(implements_net_packet_conn *self, void *buf, size_t len, struct net_ip4_addr node, uint16_t port); + /** + * @return The full length of the message, which may be more + * than the given `len` (as if the Linux MSG_TRUNC flag were + * given). + */ ssize_t (*recvfrom)(implements_net_packet_conn *self, void *buf, size_t len, struct net_ip4_addr *ret_node, uint16_t *ret_port); |