summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: f383959)
raw | patch | inline | side by side (parent: f383959)
author | Shawn O. Pearce <spearce@spearce.org> | |
Tue, 18 Sep 2007 08:54:48 +0000 (04:54 -0400) | ||
committer | Junio C Hamano <gitster@pobox.com> | |
Wed, 19 Sep 2007 10:22:31 +0000 (03:22 -0700) |
If we are fetching something and were configured to do a forced
fetch and have no local ref to store the fetched object into we
cannot mark the local ref as having a forced update. Instead we
should just silently discard the + request.
Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
fetch and have no local ref to store the fetched object into we
cannot mark the local ref as having a forced update. Instead we
should just silently discard the + request.
Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
remote.c | patch | blob | history |
diff --git a/remote.c b/remote.c
index 73a34c9e36a73db21870c36dacf05cad2c9b22c7..af3c46bb35cb77db184447afd14e1cd434e7a9f5 100644 (file)
--- a/remote.c
+++ b/remote.c
refspec->src : "HEAD");
ref_map->peer_ref = get_local_ref(refspec->dst);
-
- if (refspec->force)
+ if (ref_map->peer_ref && refspec->force)
ref_map->peer_ref->force = 1;
}