]> err.no Git - varnish/commitdiff
Don't list gone bans.
authorphk <phk@d4fa192b-c00b-0410-8231-f00ffab90ce4>
Sun, 18 Jan 2009 15:14:54 +0000 (15:14 +0000)
committerphk <phk@d4fa192b-c00b-0410-8231-f00ffab90ce4>
Sun, 18 Jan 2009 15:14:54 +0000 (15:14 +0000)
Emit && \ for line continuation.

git-svn-id: svn+ssh://projects.linpro.no/svn/varnish/trunk@3517 d4fa192b-c00b-0410-8231-f00ffab90ce4

varnish-cache/bin/varnishd/cache_ban.c

index f97a571beae5c315c0c7d22b951c730bd79de148..0a0b33babe6d2ebfed2bee68253884f135022563 100644 (file)
@@ -518,14 +518,16 @@ ccf_purge_list(struct cli *cli, const char * const *av, void *priv)
        Lck_Unlock(&ban_mtx);
 
        VTAILQ_FOREACH(b, &ban_head, list) {
+               if (b->flags & BAN_F_GONE)
+                       continue;
                bt = VTAILQ_FIRST(&b->tests);
-               cli_out(cli, "%5u %4s\t%s\n",
-                   b->refcount, b->flags ? "Gone" : "", bt->test);
+               cli_out(cli, "%5u\t%s", b->refcount, bt->test);
                do {
                        bt = VTAILQ_NEXT(bt, list);
                        if (bt != NULL)
-                               cli_out(cli, "\t\t%s\n", bt->test);
+                               cli_out(cli, " && \\\n\t%s", bt->test);
                } while (bt != NULL);
+               cli_out(cli, "\n");
        }
 
        Lck_Lock(&ban_mtx);