]> err.no Git - varnish/commitdiff
Only emit debug message for writes that fail
authorphk <phk@d4fa192b-c00b-0410-8231-f00ffab90ce4>
Mon, 24 Nov 2008 14:41:36 +0000 (14:41 +0000)
committerphk <phk@d4fa192b-c00b-0410-8231-f00ffab90ce4>
Mon, 24 Nov 2008 14:41:36 +0000 (14:41 +0000)
git-svn-id: svn+ssh://projects.linpro.no/svn/varnish/trunk@3427 d4fa192b-c00b-0410-8231-f00ffab90ce4

varnish-cache/bin/varnishd/cache_pool.c

index 81376a124fad1e5151c91e64e543de39100ee6db..d461765896707d9a3c096d011c4d01bdab9e983b 100644 (file)
@@ -124,11 +124,12 @@ WRK_Flush(struct worker *w)
        CHECK_OBJ_NOTNULL(w, WORKER_MAGIC);
        if (*w->wfd >= 0 && w->niov > 0 && w->werr == 0) {
                i = writev(*w->wfd, w->iov, w->niov);
-               if (i != w->liov)
+               if (i != w->liov) {
                        w->werr++;
-               WSL(w, SLT_Debug, *w->wfd,
-                   "Write error, len = %d/%d, errno = %s",
-                   i, w->liov, strerror(errno));
+                       WSL(w, SLT_Debug, *w->wfd,
+                           "Write error, len = %d/%d, errno = %s",
+                           i, w->liov, strerror(errno));
+               }
        }
        w->liov = 0;
        w->niov = 0;