[prev in list] [next in list] [prev in thread] [next in thread]
List: varnish-commit
Subject: [master] e0bbedd73 avoid 3 duplicated lines (very minor)
From: Nils Goroll <nils.goroll () uplex ! de>
Date: 2019-09-30 13:30:07
Message-ID: 20190930133007.50884A1FB4 () lists ! varnish-cache ! org
[Download RAW message or body]
commit e0bbedd731537e4c3b067e3593a5edb5664c0f79
Author: Nils Goroll <nils.goroll@uplex.de>
Date: Mon Sep 30 15:22:17 2019 +0200
avoid 3 duplicated lines (very minor)
Ref #3067
diff --git a/lib/libvcc/vcc_backend.c b/lib/libvcc/vcc_backend.c
index f4f4f760b..b943cf5fd 100644
--- a/lib/libvcc/vcc_backend.c
+++ b/lib/libvcc/vcc_backend.c
@@ -321,10 +321,12 @@ vcc_ParseHostDef(struct vcc *tl, const struct token *t_be, const char *vgcname)
"?proxy_header",
NULL);
- if (tl->t->tok == ID && (vcc_IdIs(tl->t, "none") || vcc_IdIs(tl->t, "None"))) {
- vsb = VSB_new_auto();
- AN(vsb);
- tl->fb = vsb;
+ vsb = VSB_new_auto();
+ AN(vsb);
+ tl->fb = vsb;
+
+ if (tl->t->tok == ID &&
+ (vcc_IdIs(tl->t, "none") || vcc_IdIs(tl->t, "None"))) {
Fb(tl, 0, "\n\t%s = (NULL);\n", vgcname);
vcc_NextToken(tl);
SkipToken(tl, ';');
@@ -333,10 +335,6 @@ vcc_ParseHostDef(struct vcc *tl, const struct token *t_be, const char *vgcname)
SkipToken(tl, '{');
- vsb = VSB_new_auto();
- AN(vsb);
- tl->fb = vsb;
-
Fb(tl, 0, "\nstatic const struct vrt_backend vgc_dir_priv_%s = {\n",
vgcname);
_______________________________________________
varnish-commit mailing list
varnish-commit@varnish-cache.org
https://www.varnish-cache.org/lists/mailman/listinfo/varnish-commit
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic