From: Joel Rosdahl Date: Sun, 1 Aug 2010 12:03:23 +0000 (+0200) Subject: Stop loop in stats_flush() when possible X-Git-Tag: v3.1~127 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=789cb1559f3cb36aa4534caff5d7da8203c9e05e;p=thirdparty%2Fccache.git Stop loop in stats_flush() when possible --- diff --git a/stats.c b/stats.c index 841e97c5d..3bf9df90d 100644 --- a/stats.c +++ b/stats.c @@ -172,6 +172,7 @@ void stats_flush(void) for (i = 0; i < STATS_END; ++i) { if (counter_updates[i] > 0) { should_flush = 1; + break; } } if (!should_flush) return;