diff options
author | Andrei Pavel <andrei.pavel@qualitance.com> | 2019-06-13 16:42:44 +0200 |
---|---|---|
committer | Andrei Pavel <andrei.pavel@qualitance.com> | 2019-06-13 16:42:44 +0200 |
commit | 294ce95293e424e4b70909fba2e6b7ab48f03b26 (patch) | |
tree | 0b91bb2a6c1fd0143fb27f228f2b6d9dc5df0a0a /src/bin/perfdhcp/basic_scen.cc | |
parent | [#590, !380] updated ChangeLog (diff) | |
download | kea-294ce95293e424e4b70909fba2e6b7ab48f03b26.tar.xz kea-294ce95293e424e4b70909fba2e6b7ab48f03b26.zip |
[🐛 FIX] perfdhcp doesn't send during exit wait time
Diffstat (limited to 'src/bin/perfdhcp/basic_scen.cc')
-rw-r--r-- | src/bin/perfdhcp/basic_scen.cc | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/bin/perfdhcp/basic_scen.cc b/src/bin/perfdhcp/basic_scen.cc index fe811c4e11..84ec5be9b9 100644 --- a/src/bin/perfdhcp/basic_scen.cc +++ b/src/bin/perfdhcp/basic_scen.cc @@ -139,7 +139,8 @@ BasicScen::run() { for (;;) { // Calculate number of packets to be sent to stay // catch up with rate. - uint64_t packets_due = basic_rate_control_.getOutboundMessageCount(); + uint64_t packets_due = + basic_rate_control_.getOutboundMessageCount(!tc_.exit_time_.is_not_a_date_time()); if ((packets_due == 0) && options_.testDiags('i')) { stats_mgr.incrementCounter("shortwait"); } @@ -171,7 +172,7 @@ BasicScen::run() { // Renew packets should be sent to catch up with a desired rate. if (options_.getRenewRate() != 0) { uint64_t renew_packets_due = - renew_rate_control_.getOutboundMessageCount(); + renew_rate_control_.getOutboundMessageCount(!tc_.exit_time_.is_not_a_date_time()); // Send multiple renews to satisfy the desired rate. if (options_.getIpVersion() == 4) { @@ -185,7 +186,7 @@ BasicScen::run() { // Release messages should be sent to catch up with a desired rate. if ((options_.getIpVersion() == 6) && (options_.getReleaseRate() != 0)) { uint64_t release_packets_due = - release_rate_control_.getOutboundMessageCount(); + release_rate_control_.getOutboundMessageCount(!tc_.exit_time_.is_not_a_date_time()); // Send Release messages. tc_.sendMultipleMessages6(DHCPV6_RELEASE, release_packets_due); } |