improved the scap buffer timeout logic