Skip to content

Commit

Permalink
fixed bug in statistics decision making if one should publish (ros#1625)
Browse files Browse the repository at this point in the history
  • Loading branch information
wentz89 authored and tahsinkose committed Apr 15, 2019
1 parent db188f3 commit 92ad50f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion clients/roscpp/src/libros/statistics.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ void StatisticsLogger::callback(const boost::shared_ptr<M_string>& connection_he
}

// should publish new statistics?
if (stats.last_publish + ros::Duration(pub_frequency_) < received_time)
if (stats.last_publish + ros::Duration(1 / pub_frequency_) < received_time)
{
ros::Time window_start = stats.last_publish;
stats.last_publish = received_time;
Expand Down

0 comments on commit 92ad50f

Please sign in to comment.