fix timeout initialization bug