Function pcqueue_peek

Function Documentation

status_t pcqueue_peek(struct pcqueue *const queue, void **const e)

Get the first element in the queue if it exists, with a timeout.

Note

The filled value returned by this function cannot be relied upon in a multi-threaded context without additional synchronization.

Parameters:
  • queue – The queue handle.

  • e – To be filled with the address of the first element, if it exists, and set to NULL otherwise.

Returns:

status_t.