There's no point in storing blob, they would increase the time of
loading the marks, and the vast majority of them will never be used
again.

This also makes fast-export and fast-import marks compatible.

Signed-off-by: Felipe Contreras <felipe.contre...@gmail.com>
---
 fast-import.c | 9 +++++++--
 1 file changed, 7 insertions(+), 2 deletions(-)

diff --git a/fast-import.c b/fast-import.c
index e02f212..c583975 100644
--- a/fast-import.c
+++ b/fast-import.c
@@ -1743,9 +1743,14 @@ static void dump_marks_helper(FILE *f,
                }
        } else {
                for (k = 0; k < 1024; k++) {
-                       if (m->data.marked[k])
+                       if (m->data.marked[k]) {
+                               struct object_entry *e;
+                               e = m->data.marked[k];
+                               if (e->type != OBJ_COMMIT)
+                                       continue;
                                fprintf(f, ":%" PRIuMAX " %s\n", base + k,
-                                       
sha1_to_hex(m->data.marked[k]->idx.sha1));
+                                       sha1_to_hex(e->idx.sha1));
+                       }
                }
        }
 }
-- 
1.8.3.rc0.401.g45bba44

--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to