[master] 681dc94 fix optional argument handling in vmod_shard_remove_backend()

Nils Goroll nils.goroll at uplex.de
Mon Mar 12 12:30:12 UTC 2018


commit 681dc94b52be3cac41bc58dcd0759614955f361f
Author: Nils Goroll <nils.goroll at uplex.de>
Date:   Mon Mar 12 13:28:02 2018 +0100

    fix optional argument handling in vmod_shard_remove_backend()
    
    Thank you to phk for spotting this!

diff --git a/lib/libvmod_directors/vmod_shard.c b/lib/libvmod_directors/vmod_shard.c
index 21a73eb..9b42e5a 100644
--- a/lib/libvmod_directors/vmod_shard.c
+++ b/lib/libvmod_directors/vmod_shard.c
@@ -318,7 +318,7 @@ vmod_shard_remove_backend(VRT_CTX, struct vmod_directors_shard *vshard,
     struct vmod_shard_remove_backend_arg *args)
 {
 	VCL_BACKEND be = args->valid_backend ? args->backend : NULL;
-	VCL_STRING ident = args->ident ? args->ident : NULL;
+	VCL_STRING ident = args->valid_ident ? args->ident : NULL;
 
 	CHECK_OBJ_NOTNULL(vshard, VMOD_SHARD_SHARD_MAGIC);
 


More information about the varnish-commit mailing list