riot_sys

Function ipv6_addr_from_buf

Source
pub unsafe extern "C" fn ipv6_addr_from_buf(
    result: *mut ipv6_addr_t,
    addr: *const c_char,
    addr_len: size_t,
) -> *mut ipv6_addr_t
Expand description

@brief Converts an IPv6 address from a buffer of characters to a byte-represented IPv6 address

@see RFC 5952

@note @p addr_len should be between 0 and IPV6_ADDR_MAX_STR_LEN

@param[out] result The resulting byte representation @param[in] addr An IPv6 address string representation @param[in] addr_len The amount of characters to parse

@return @p result, on success @return NULL, if @p addr was malformed @return NULL, if @p result or @p addr was NULL