[riot-notifications] [RIOT] conn: extend API with timeout support (#3921)
notifications at github.com
Tue Sep 22 06:46:17 CEST 2015
> + * @param[out] addr NULL pointer or the sender's network layer address. Must have space
> + * for any address of the connection's family.
> + * @param[out] addr_len Length of @p addr. Can be NULL if @p addr is NULL.
> + * @param[out] port NULL pointer or the sender's UDP port.
> + * @param[in] timeout The timeout in milliseconds the receive should wait
> + *
> + * @note Function may block.
> + *
> + * @return The number of bytes received on success.
> + * @return 0, if no received data is available, but everything is in order.
> + * @return any other negative number in case of an error. For portability, implementations should
> + * draw inspiration of the errno values from the POSIX' recv(), recvfrom(), or recvmsg()
> + * function specification.
> + */
> +int conn_udp_recvfrom_timeout(conn_udp_t *conn, void *data, size_t max_len, void *addr, size_t *addr_len,
> + uint16_t *port, uint32_t timeout);
How are we dealing with stacks that don't provide timeout capabilities? @kaspar030 does your stack provide them, or is that to fat?
Reply to this email directly or view it on GitHub:
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the notifications