function lfds711_queue_bss_cleanup

From liblfds.org
Revision as of 18:11, 16 February 2017 by Admin (talk | contribs) (1 revision imported)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Source Files

└───liblfds711
    ├───inc
    │   └───liblfds711
    │           lfds711_queue_bounded_singleproducer_singleconsumer.h
    └───src
        └───lfds711_queue_bounded_singleproducer_singleconsumer
                lfds711_queue_bounded_singleproducer_singleconsumerr_cleanup.c

Opaque Structures

struct lfds711_queue_bss_state;

Prototype

void lfds711_queue_bss_cleanup( struct lfds711_queue_bss_state *qbsss, void (*element_cleanup_callback)(struct lfds711_queue_bss_state *qbsss, void *key, void *value) );

Parameters

struct lfds711_queue_bss_state *qbsss

A pointer to an initialized struct lfds711_queue_bss_state.

void (*element_cleanup_callback)(struct lfds711_queue_bss_state *qbsss, void *key, void *value)

A callback function which is called with every element present in the queue at the time of cleanup. This argument can be NULL.

Notes

This function cleans up an initialized queue. If element_cleanup_callback is not NULL, it is called once for each element in the queue.

After lfds711_queue_bss_cleanup is complete, the user is safe to deallocate the store used for the queue state.

See Also