Merge branch 'jc/mention-tracking-for-pull-default'
[git.git] / fetch-pack.c
index f0acdf7331eeaf7a55ad09309a788c5971fe9b7f..6d8926a5504a6cd93e19860f85d58816bdd5c222 100644 (file)
@@ -594,6 +594,9 @@ static int everything_local(struct fetch_pack_args *args,
        for (ref = *refs; ref; ref = ref->next) {
                struct object *o;
 
+               if (!has_sha1_file(ref->old_sha1))
+                       continue;
+
                o = parse_object(ref->old_sha1);
                if (!o)
                        continue;