telnet: fix "cast increases required alignment of target type"