openthread_sys

Function otIp6PrefixFromString

Source
pub unsafe extern "C" fn otIp6PrefixFromString(
    aString: *const c_char,
    aPrefix: *mut otIp6Prefix,
) -> otError
Expand description

Converts a human-readable IPv6 prefix string into a binary representation.

The @p aString parameter should be a string in the format “

/”, where <address> is an IPv6 address and <plen> is a prefix length.

@param[in] aString A pointer to a NULL-terminated string. @param[out] aPrefix A pointer to an IPv6 prefix.

@retval OT_ERROR_NONE Successfully parsed the string as an IPv6 prefix and updated @p aPrefix. @retval OT_ERROR_PARSE Failed to parse @p aString as an IPv6 prefix.