Standarlize GET_CHAR_IS_BUFFERED.

Also fixed various telnet related issue.
Also fixed #206.