Completed server and multithreaded it.
Minor modification to client.