| -rw-r--r-- | ui-refs.c | 3 |
1 files changed, 3 insertions, 0 deletions
@@ -97,6 +97,9 @@ static void print_tag_downloads(const struct cgit_repo *repo, const char *ref) struct strbuf filename = STRBUF_INIT; size_t prefixlen; + if (!ref || strlen(ref) < 1) + return; + basename = cgit_snapshot_prefix(repo); if (starts_with(ref, basename)) strbuf_addstr(&filename, ref); |