Make the raw protocol to a real protocol. It sends the message size now before the message. This was neccessary because after I activated optimization in gcc the testclient was always only reading 2 bytes in the initial successfull read.