test tcp socket in c