Mailing List Archive

[master] cd1f75af4 Use VSB_destroy() where applicable
commit cd1f75af4fbbb7bcd3d5ca4f907d469576134404
Author: Poul-Henning Kamp <phk@FreeBSD.org>
Date: Tue Aug 4 10:53:08 2020 +0000

Use VSB_destroy() where applicable

diff --git a/bin/varnishd/mgt/mgt_param.c b/bin/varnishd/mgt/mgt_param.c
index bbd8700ec..32b1501c2 100644
--- a/bin/varnishd/mgt/mgt_param.c
+++ b/bin/varnishd/mgt/mgt_param.c
@@ -738,7 +738,7 @@ MCF_ParamConf(enum mcf_which_e which, const char * const param,
va_end(ap);
AZ(VSB_finish(vsb));
mcf_dyn_vsb(which, pp, vsb);
- VSB_delete(vsb);
+ VSB_destroy(&vsb);
}

/*--------------------------------------------------------------------*/
diff --git a/bin/varnishd/proxy/cache_proxy_proto.c b/bin/varnishd/proxy/cache_proxy_proto.c
index f825273b2..1cc36d47f 100644
--- a/bin/varnishd/proxy/cache_proxy_proto.c
+++ b/bin/varnishd/proxy/cache_proxy_proto.c
@@ -755,7 +755,7 @@ VPX_Send_Proxy(int fd, int version, const struct sess *sp)
version == 2 ? VSB_QUOTE_HEX : 0);
AZ(VSB_finish(vsb2));
VSL(SLT_Debug, 999, "PROXY_HDR %s", VSB_data(vsb2));
- VSB_delete(vsb2);
+ VSB_destroy(&vsb2);
return (r);
}

diff --git a/lib/libvarnish/vsb_test.c b/lib/libvarnish/vsb_test.c
index 9ac60154c..8ce277c65 100644
--- a/lib/libvarnish/vsb_test.c
+++ b/lib/libvarnish/vsb_test.c
@@ -44,7 +44,7 @@ main(int argc, char *argv[])
printf("\n");
VSB_clear(vsb);
}
- VSB_delete(vsb);
+ VSB_destroy(&vsb);
printf("error is %i\n", err);
return (err);
}
diff --git a/lib/libvmod_vtc/vmod_vtc.c b/lib/libvmod_vtc/vmod_vtc.c
index b2b9afd7d..bc95fcb84 100644
--- a/lib/libvmod_vtc/vmod_vtc.c
+++ b/lib/libvmod_vtc/vmod_vtc.c
@@ -362,7 +362,7 @@ vmod_proxy_header(VRT_CTX, VCL_ENUM venum, VCL_IP client, VCL_IP server,
VRT_Format_Proxy(vsb, version, client, server, authority);
l = VSB_len(vsb);
h = WS_Copy(ctx->ws, VSB_data(vsb), l);
- VSB_delete(vsb);
+ VSB_destroy(&vsb);

if (h == NULL) {
VRT_fail(ctx, "proxy_header: out of workspace");
_______________________________________________
varnish-commit mailing list
varnish-commit@varnish-cache.org
https://www.varnish-cache.org/lists/mailman/listinfo/varnish-commit