Fix #42 and #26

This patch fixes connection with mstsc 7600. It also desactivate NS codec.
It also fixes bugs when the frontend client disconnect uncleanly.