Simple chat server implementation written in C