diff options
author | Alecs King <alecsk@gmail.com> | 2005-08-04 11:35:37 +0800 |
---|---|---|
committer | Junio C Hamano <junkio@cox.net> | 2005-08-03 21:41:56 -0700 |
commit | 635d37afff321a9c296ed5d6e0203f2a1c91373f (patch) | |
tree | 74400f7c5508ef9cb635d8a9cab95dfe81747003 /connect.c | |
parent | 20f6633112c2a95b4907b4ff2e41e3c450395d34 (diff) | |
download | git-635d37afff321a9c296ed5d6e0203f2a1c91373f.tar.gz |
[PATCH] Fix sparse warnings
fix one 'should it be static?' warning and
two 'mixing declarations and code' warnings.
Signed-off-by: Alecs King <alecsk@gmail.com>
Signed-off-by: Junio C Hamano <junkio@cox.net>
Diffstat (limited to 'connect.c')
-rw-r--r-- | connect.c | 4 |
1 files changed, 1 insertions, 3 deletions
@@ -230,11 +230,9 @@ int match_refs(struct ref *src, struct ref *dst, struct ref ***dst_tail, if (src->peer_ref) continue; dst_peer = find_ref_by_name(dst, src->name); - if (dst_peer && dst_peer->peer_ref) + if ((dst_peer && dst_peer->peer_ref) || (!dst_peer && !all)) continue; if (!dst_peer) { - if (!all) - continue; /* Create a new one and link it */ int len = strlen(src->name) + 1; dst_peer = xcalloc(1, sizeof(*dst_peer) + len); |