Wait for Data?

Ok so I made a server connection with AC3 and C, I need the client(AC3) to be able to send a 3 byte message to the server © and have the server return a resopnse. So far everything works except for the fact that the feedback isn’t fast enough becuase AC3 just tests for data once and moves on instead of waiting like in C. I’m using a binary socket at the moment but I was wondering if there was any way to wait for new data before moving on