Changed PrintWriters and BufferedReaders to DataInput/OutputStreams for compatibility between different systems. Println() methods of PrintWriter is problematic if clients are on different platforms than servers.