Linear Containers API Reference
Linked lists and Queues
IotListDouble_RemoveFirstMatch

Search a doubly-linked list for the first matching element and remove it.

static inline IotLink_t * IotListDouble_RemoveFirstMatch( const IotListDouble_t * const pList,
const IotLink_t * const pStartPoint,
bool ( * isMatch )( const IotLink_t * const pOperationLink, void * pCompare ),
void * pMatch )

An IotLink_t may be passed as pList to start searching after the head of a doubly-linked list.

Parameters
[in]pListThe doubly-linked list to search.
[in]pStartPointAn element in pList. Only elements between this one and the list tail are checked. Pass NULL to search from the beginning of the list.
[in]isMatchFunction to determine if an element matches. Pass NULL to search using the address pMatch, i.e. element == pMatch.
[in]pMatchIf isMatch is NULL, each element in the list is compared to this address to find a match. Otherwise, it is passed as the second argument to isMatch.
Returns
Pointer to an IotLink_t representing the matched and removed element; NULL if no match is found. The macro IotLink_Container may be used to determine the address of the link's container.