Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

16 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

queueforge

Small C project that implements binary message parsing, a fixed-size ring buffer, and a thread-safe producer-consumer queue based on pthread.

The project is built around a simple binary message format. Parsed messages are stored in a ring buffer and can also be passed between producer and consumer threads through a thread-safe queue wrapper.

Message format

Each message is represented as a byte buffer with the following layout:

+---------+----------+------------+------------+--------------+
| magic   | version  | msg_type   | channel_id | payload_len  |
| 2 bytes | 1 byte   | 1 byte     | 2 bytes    | 2 bytes      |
+---------+----------+------------+------------+--------------+
| payload                                              |
| payload_len bytes                                    |
+------------------------------------------------------+
| checksum                                             |
| 1 byte                                               |
+------------------------------------------------------+

Build

Build main target with:

make

Test everything with:

make test

About

C project exploring binary parsing, ring buffers, and thread-safe producer-consumer queues.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages