From fb89a2c22758c37f1adb80dd52880fd5b99943bf Mon Sep 17 00:00:00 2001 From: Johannes Schindelin Date: Sat, 23 Jul 2011 15:40:23 +0200 Subject: [PATCH] fast-export: do not export negative refs When calling `git fast-export master..next` we want to export refs/heads/next, but not refs/heads/master. Currently this is not a problem, because negative refs' commits are never shown. In the next commit this will be changed in order to make sure that 'master..master' does export master. I.e. even refs whose commits are not shown are exported. Signed-off-by: Johannes Schindelin Signed-off-by: Sverre Rabbelier --- builtin/fast-export.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/builtin/fast-export.c b/builtin/fast-export.c index 216c54ade8..77a7c20547 100644 --- a/builtin/fast-export.c +++ b/builtin/fast-export.c @@ -486,7 +486,7 @@ static void get_tags_and_duplicates(struct object_array *pending, struct commit *commit = commit; char *full_name; - if (dwim_ref(e->name, strlen(e->name), sha1, &full_name) != 1) + if ((e->flags & UNINTERESTING) || dwim_ref(e->name, strlen(e->name), sha1, &full_name) != 1) continue; switch (e->item->type) { -- 2.11.4.GIT