client.c code explained