You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
339 B
339 B
Circular buffer
This is a C implementation of a circular buffer, which can also be used as a queue or stack.
To achieve thread safety (to some extent) in a producent-consumer situation, there is no length variable, only write pointers. Due to not using a length variable, one element in the buffer is always left unused.