diff options
author | Sebastian Hahn <sebastian@torproject.org> | 2012-01-22 13:39:56 +0100 |
---|---|---|
committer | Roger Dingledine <arma@torproject.org> | 2012-02-08 04:44:15 -0500 |
commit | 332e96d1098b00ab21e635a19e9b427d3c735e33 (patch) | |
tree | 00689ebf7c3296604854a8b99ee97cdcf9ad69fb /src | |
parent | 9bcf315e9bdb063a09cdb824803dac1bd607a217 (diff) | |
download | tor-332e96d1098b00ab21e635a19e9b427d3c735e33.tar.gz tor-332e96d1098b00ab21e635a19e9b427d3c735e33.zip |
Fix fencepost error with HearbeatPeriod option
We'd only log every HeartbeatPeriod + 1 seconds. Discovered by Scott
Bennett, reported as bug 4942.
Diffstat (limited to 'src')
-rw-r--r-- | src/or/main.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/or/main.c b/src/or/main.c index 7ef14aaa76..9022f2eb87 100644 --- a/src/or/main.c +++ b/src/or/main.c @@ -1533,7 +1533,7 @@ run_scheduled_events(time_t now) /** 12. write the heartbeat message */ if (options->HeartbeatPeriod && - time_to_next_heartbeat < now) { + time_to_next_heartbeat <= now) { log_heartbeat(now); time_to_next_heartbeat = now+options->HeartbeatPeriod; } |