added UNIX specific sleep