Improved timeout management