Fixed a spelling mistake in the documentation.
Fixed a bug in the socket class and a memory leak in the controller class.