Fix corner-case in handling of remaining retry time
authorKlaus Aehlig <aehlig@google.com>
Thu, 19 Sep 2013 16:12:21 +0000 (18:12 +0200)
committerKlaus Aehlig <aehlig@google.com>
Fri, 20 Sep 2013 12:21:35 +0000 (14:21 +0200)
commit34098a73bd9749e25b4df76a4bdecaeb573cb97f
treed0bed24f94be80ecd8091d59db78d6fa27d06320
parent80adbbe1a8cb0b95927edefac5f502414ef7ed6c
Fix corner-case in handling of remaining retry time

Consider a remaining time of 0 as already timed out. Otherwise,
there is no guarantee that calling utils.Retry with timeout 0
will call the function precisely once; it might run in time
shorter than the resolution of timer.

Signed-off-by: Klaus Aehlig <aehlig@google.com>
Reviewed-by: Thomas Thrainer <thomasth@google.com>
lib/utils/retry.py