openbmc/build/tmp/deploy/sdk/witherspoon-2019-08-08/sysroots/armv6-openbmc-linux-gnueabi/usr/src/debug/sysfsutils/2.1.0-r5/sysfsutils-2.1.0/lib/dlist.c
void* dlist_find_custom(struct dlist* list, void* target,
                        int (*comp)(void*, void*))
{
    /* test the comp function on each node */
    struct dl_node* nodepointer;
    dlist_for_each_nomark(
        list,
        nodepointer) if (comp(target,
                              nodepointer->data)) return (nodepointer->data);
    return (NULL);
}
/**
 *  Return void pointer to list_data element matching comp function criteria
 *  else null
 *  Does not move the marker.
 */
Return void pointer to list_data element matching comp function criteria
else null
Does not move the marker.
Return void pointer to list_data element matching comp function criteria else null Does not move the marker .
void* dlist_find_custom(struct dlist* list, void* target,
                        int (*comp)(void*, void*))
{
    struct dl_node* nodepointer;
    dlist_for_each_nomark(
        list,
        nodepointer) if (comp(target,
                              nodepointer->data)) return (nodepointer->data);
    return (NULL);
}
void * dlist_find_custom ( struct dlist * list , void * target , int ( * comp ) ( void * , void * ) ) { struct dl_node * nodepointer ; dlist_for_each_nomark ( list , nodepointer ) if ( comp ( target , nodepointer -> data ) ) return ( nodepointer -> data ) ; return ( NULL ) ; }
Return void pointer to list_data element matching comp function criteria
  else null
  Does not move the marker.
Return void pointer to list_data element matching comp function criteria else null Does not move the marker .
/* test the comp function on each node */