do not check truth value of flex arrays

There is no point in checking "!ref->name" when ref is a "struct ref". The name field is a flex-array, and there always has a non-zero address. This is almost certainly not hurting anything, but it does cause clang-3.6 to complain. Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>

Jeff King committed Jan 28, 2015 at 12:58 UTC 94ee8e2c98cf4adf0c69b3b8ce5039eea92347b7
1 file changed +1 -1
remote-curl.c
+1 -1
@@ -514,7 +514,7 @@ static int fetch_git(struct discovery *heads,
514 argv[argc++] = url;
515 for (i = 0; i < nr_heads; i++) {
516 struct ref *ref = to_fetch[i];
517 - if (!ref->name || !*ref->name)
517 + if (!*ref->name)
518 die("cannot fetch by sha1 over smart http");
519 argv[argc++] = ref->name;
520 }