Fix issue #178

This patch is extracting the current TERM of the user instead of forcing
it to "xterm". This fix was only tested on my server.