Function esp_idf_svc::hal::sys::esp_netif_next

source ·
pub unsafe extern "C" fn esp_netif_next(
    esp_netif: *mut esp_netif_obj,
) -> *mut esp_netif_obj
Expand description

@brief Iterates over list of interfaces. Returns first netif if NULL given as parameter

@note This API doesn’t lock the list, nor the TCPIP context, as this it’s usually required to get atomic access between iteration steps rather that within a single iteration. Therefore it is recommended to iterate over the interfaces inside esp_netif_tcpip_exec()

@note This API is deprecated. Please use esp_netif_next_unsafe() directly if all the system interfaces are under your control and you can safely iterate over them. Otherwise, iterate over interfaces using esp_netif_tcpip_exec(), or use esp_netif_find_if() to search in the list of netifs with defined predicate.

@param[in] esp_netif Handle to esp-netif instance

@return First netif from the list if supplied parameter is NULL, next one otherwise