14 #include <sys/types.h>
File containing macros for compiler attributes, if they are supported.
#define __must_free
Definition: attributes.h:94
void free_string_queue(struct string_queue *queue)
Frees the string queue.
Definition: squeue.c:114
int pop_string_queue(struct string_queue *queue, char **str)
Extract the first string from the string queueu.
Definition: squeue.c:90
void free_string_queue_el(struct string_queue *el)
Delete a string entry.
Definition: squeue.c:67
int peek_string_queue(const struct string_queue *queue, char **str)
Peek the first string from the string queueu.
Definition: squeue.c:75
int push_string_queue(struct string_queue *queue, const char *str)
Pushes a string in the string queue.
Definition: squeue.c:34
void empty_string_queue(struct string_queue *queue, ssize_t count)
Empty a string entry.
Definition: squeue.c:102
__must_free char * concat_string_queue(const struct string_queue *queue, ssize_t count)
Concat the first count string in the queue.
Definition: squeue.c:125
ssize_t get_string_queue_length(const struct string_queue *queue)
Returns the string queue length.
Definition: squeue.c:121
struct string_queue * init_string_queue(ssize_t max_length)
Initialises and empty string queue.
Definition: squeue.c:18
String queue structure definition.
Definition: squeue.h:24
char * str
Definition: squeue.h:25
struct dl_list list
Definition: squeue.h:27
ssize_t max_length
Definition: squeue.h:26