socket_samples in c lang