Fixed T-server bugs and tested [working ok]