Fix wait timeout