Added leak checks to the tests.
Fixed memory leaks.
Got rid of the obsolete client/server.
Updated server tests.