bitrate: fix integer roundoff
authorRemy Horton <remy.horton@intel.com>
Wed, 19 Apr 2017 13:26:48 +0000 (14:26 +0100)
committerThomas Monjalon <thomas@monjalon.net>
Thu, 20 Apr 2017 23:08:07 +0000 (01:08 +0200)
commit0caf72811441b42cb14a28c72007f8ef35b453d6
tree921717fed004fc0f12e7078771771225f3aeb52e
parent917f49cfd0d1fc6c1ae890528835ece018741baa
bitrate: fix integer roundoff

In the absence of traffic, it is possible for the bitrate moving average
to get stuck at a non-zero value, due to the calculated delta being less
than what an integer can represent.

Fixes: 2ad7ba9a6567 ("bitrate: add bitrate statistics library")

Signed-off-by: Remy Horton <remy.horton@intel.com>
lib/librte_bitratestats/rte_bitrate.c