]> git.ipfire.org Git - thirdparty/ccache.git/commitdiff
Stop loop in stats_flush() when possible
authorJoel Rosdahl <joel@rosdahl.net>
Sun, 1 Aug 2010 12:03:23 +0000 (14:03 +0200)
committerJoel Rosdahl <joel@rosdahl.net>
Sun, 1 Aug 2010 15:20:33 +0000 (17:20 +0200)
stats.c

diff --git a/stats.c b/stats.c
index 841e97c5d124d697e481898ac546c1d7496bb9d5..3bf9df90d19d9da79e0e0bc0f3803bb8699bac13 100644 (file)
--- 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;