summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: ea47de8)
raw | patch | inline | side by side (parent: ea47de8)
author | Wilfried Goesgens <dothebart@citadel.org> | |
Sat, 21 Jun 2014 19:14:28 +0000 (21:14 +0200) | ||
committer | Wilfried Goesgens <dothebart@citadel.org> | |
Sat, 21 Jun 2014 19:14:28 +0000 (21:14 +0200) |
src/utils_latency.c | patch | blob | history |
diff --git a/src/utils_latency.c b/src/utils_latency.c
index 94da2112ec1971410f9b54870b9694ac35388b84..bfe91fd837dcf5061efa5793e88ff8f4d68bfcdd 100644 (file)
--- a/src/utils_latency.c
+++ b/src/utils_latency.c
{
double average;
- if (lc == NULL)
+ if ((lc == NULL) || (lc->num == 0))
return (0);
average = CDTIME_T_TO_DOUBLE (lc->sum) / ((double) lc->num);