#!/bin/ash
#
# telnet via netcat, by M. Andreoli
# Some problem with terminal settings

host=$1
port=$2

if [ -z "${host}" ] ; then
	read -p "hostname: " host
fi

echo 
echo " ** Please: ignore garbage!"
echo " ** If You have problem with terminal settings," 
echo " ** try with telnet2 (rlogin) and "
echo " ** issue an export TERM=linux on remote side."
echo

exec /usr/bin/nc -t $host ${port:-23}

