AB - Added timeout to detect a broken socket