[master] 2f02345a4 Code compaction after Dridilinting

Nils Goroll nils.goroll at uplex.de
Wed Sep 29 10:39:05 UTC 2021


commit 2f02345a4868e309f36d9c4a38c44ba50a1374ae
Author: Nils Goroll <nils.goroll at uplex.de>
Date:   Wed Sep 29 12:38:15 2021 +0200

    Code compaction after Dridilinting
    
    Ref #3707

diff --git a/bin/varnishd/storage/storage_debug.c b/bin/varnishd/storage/storage_debug.c
index aa8672fe6..ad069ef5f 100644
--- a/bin/varnishd/storage/storage_debug.c
+++ b/bin/varnishd/storage/storage_debug.c
@@ -72,12 +72,7 @@ smd_init(struct stevedore *parent, int aac, char * const *aav)
 	av = calloc(aac + 1, sizeof *av);
 	AN(av);
 	for (i = 0; i < aac; i++) {
-		if (aav[i] == NULL) {
-			AZ(av[ac]);
-			ac++;
-			continue;
-		}
-		if (! strcmp(aav[i], "lessspace")) {
+		if (aav[i] != NULL && ! strcmp(aav[i], "lessspace")) {
 			methods->objgetspace = smd_lsp_getspace;
 			continue;
 		}


More information about the varnish-commit mailing list