riot_sys::bindgen

Function ipv4_addr_from_buf

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

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

@note @p addr_len should be between 0 and IPV4_ADDR_MAX_STR_LEN

@param[out] result The resulting byte representation @param[in] addr An IPv4 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