diff options
author | Alan Conway <aconway@apache.org> | 2011-03-18 15:37:40 +0000 |
---|---|---|
committer | Alan Conway <aconway@apache.org> | 2011-03-18 15:37:40 +0000 |
commit | 8ad522efb72738fad32493be76fef9c71e5d530f (patch) | |
tree | 9981a555f111065a2a05778f5bd8ca0f75d5df03 /cpp/src/qpid/sys/Timer.cpp | |
parent | 54a99241a063d8399dfe390a36435988db6a4e51 (diff) | |
download | qpid-python-8ad522efb72738fad32493be76fef9c71e5d530f.tar.gz |
NO-JIRA: Fix qpidd late/overran warnings.
Warnings for late-and-overrun tasks were not being correctly reported.
Lateness for overrun tasks below the late threshold were not being reported.
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@1082954 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'cpp/src/qpid/sys/Timer.cpp')
-rw-r--r-- | cpp/src/qpid/sys/Timer.cpp | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/cpp/src/qpid/sys/Timer.cpp b/cpp/src/qpid/sys/Timer.cpp index a97ccd1bd1..85e410860d 100644 --- a/cpp/src/qpid/sys/Timer.cpp +++ b/cpp/src/qpid/sys/Timer.cpp @@ -131,12 +131,14 @@ void Timer::run() bool warningsEnabled; QPID_LOG_TEST(warning, warningsEnabled); if (warningsEnabled) { - if (delay > late && overrun > overran) - warn.lateAndOverran(t->name, delay, overrun, Duration(start, end)); + if (overrun > overran) { + if (delay > overran) // if delay is significant to an overrun. + warn.lateAndOverran(t->name, delay, overrun, Duration(start, end)); + else + warn.overran(t->name, overrun, Duration(start, end)); + } else if (delay > late) warn.late(t->name, delay); - else if (overrun > overran) - warn.overran(t->name, overrun, Duration(start, end)); } continue; } else { |