summaryrefslogtreecommitdiffstats
path: root/generic/tclTimer.c
diff options
context:
space:
mode:
authorjan.nijtmans <nijtmans@users.sourceforge.net>2017-04-14 13:00:46 (GMT)
committerjan.nijtmans <nijtmans@users.sourceforge.net>2017-04-14 13:00:46 (GMT)
commit2c5d1036db0d85c674967af5103c714092e279a7 (patch)
tree4078b1f733e2bb22b44c818b5618411601ebf791 /generic/tclTimer.c
parent8a2c820213312ae39df29ae3f0f3d7ef83e6d4a3 (diff)
parent15b0a7813d5d23096f735981f1af2c90e283afc6 (diff)
downloadtcl-2c5d1036db0d85c674967af5103c714092e279a7.zip
tcl-2c5d1036db0d85c674967af5103c714092e279a7.tar.gz
tcl-2c5d1036db0d85c674967af5103c714092e279a7.tar.bz2
merge trunk
Diffstat (limited to 'generic/tclTimer.c')
-rw-r--r--generic/tclTimer.c12
1 files changed, 9 insertions, 3 deletions
diff --git a/generic/tclTimer.c b/generic/tclTimer.c
index 6d3938b..3467305 100644
--- a/generic/tclTimer.c
+++ b/generic/tclTimer.c
@@ -1053,11 +1053,17 @@ AfterDelay(
if (diff > TCL_TIME_MAXIMUM_SLICE) {
diff = TCL_TIME_MAXIMUM_SLICE;
}
- if (diff == 0 && TCL_TIME_BEFORE(now, endTime)) diff = 1;
+ if (diff == 0 && TCL_TIME_BEFORE(now, endTime)) {
+ diff = 1;
+ }
if (diff > 0) {
Tcl_Sleep((long) diff);
- if (diff < SLEEP_OFFLOAD_GETTIMEOFDAY) break;
- } else break;
+ if (diff < SLEEP_OFFLOAD_GETTIMEOFDAY) {
+ break;
+ }
+ } else {
+ break;
+ }
} else {
diff = TCL_TIME_DIFF_MS(iPtr->limit.time, now);
#ifndef TCL_WIDE_INT_IS_LONG