thwait
not defined yet