#!/bin/sh# busybox' getty does this itself, util-linux' agetty needs extra helpgetty="/sbin/getty"case$(readlink -f "${getty}") in
*/busybox*);;
*)if[ -x "/usr/bin/setsid"];thensetsid="/usr/bin/setsid"fi;;esacif[ -e /sys/class/tty/$2 -a -c /dev/$2];then${setsid:-}${getty} -L $1$2$3fi