Finish client and server socket communication