What do you think about calling stats_start when count is 0 and end when it has reached the packet limit?