mirror of
https://github.com/libgit2/libgit2.git
synced 2026-06-22 06:26:26 +00:00
transport: fix capabilities calculation
This looks like a typo to me, from what i can see these lines were added at the same time and because of how capabilities are calculated, it's likely that this code will work in situations where these capabilities were the last ones.
This commit is contained in:
@@ -207,13 +207,13 @@ int git_smart__detect_caps(git_pkt_ref *pkt, transport_smart_caps *caps, git_vec
|
||||
|
||||
if (!git__prefixcmp(ptr, GIT_CAP_WANT_TIP_SHA1)) {
|
||||
caps->common = caps->want_tip_sha1 = 1;
|
||||
ptr += strlen(GIT_CAP_DELETE_REFS);
|
||||
ptr += strlen(GIT_CAP_WANT_TIP_SHA1);
|
||||
continue;
|
||||
}
|
||||
|
||||
if (!git__prefixcmp(ptr, GIT_CAP_WANT_REACHABLE_SHA1)) {
|
||||
caps->common = caps->want_reachable_sha1 = 1;
|
||||
ptr += strlen(GIT_CAP_DELETE_REFS);
|
||||
ptr += strlen(GIT_CAP_WANT_REACHABLE_SHA1);
|
||||
continue;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user