commit-tree: do not pay attention to commit.gpgsign
[gitweb.git] / builtin / for-each-ref.c
index 83f9cf91633a514e9301762fe774ee91be092848..13d217240a641586f9dc48bb5d85ea8104224aba 100644 (file)
@@ -851,6 +851,11 @@ static int grab_single_ref(const char *refname, const unsigned char *sha1, int f
                  return 0;
        }
 
+       if (flag & REF_ISBROKEN) {
+                 warning("ignoring broken ref %s", refname);
+                 return 0;
+       }
+
        if (*cb->grab_pattern) {
                const char **pattern;
                int namelen = strlen(refname);