diff options
author | David Ostrovsky <david@ostrovsky.org> | 2020-05-19 07:17:24 +0200 |
---|---|---|
committer | Thomas Wolf <thomas.wolf@paranor.ch> | 2021-01-03 16:25:01 +0100 |
commit | d9143287b778deba259cdd9d7db0a6aaba558eb2 (patch) | |
tree | f8c23a9607db94493d570dbd5840e389049a4856 /org.eclipse.jgit | |
parent | 0853a2410f22c8bd97a179dec14e3c083a27abbb (diff) | |
download | jgit-d9143287b778deba259cdd9d7db0a6aaba558eb2.tar.gz jgit-d9143287b778deba259cdd9d7db0a6aaba558eb2.zip |
Enable git wire protocol version 2 on server side per default
Bug: 563145
Change-Id: Id5030c2b85466da0a8ccf3d78ae78df16d64ffc5
Signed-off-by: David Ostrovsky <david@ostrovsky.org>
Diffstat (limited to 'org.eclipse.jgit')
-rw-r--r-- | org.eclipse.jgit/src/org/eclipse/jgit/transport/UploadPack.java | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/transport/UploadPack.java b/org.eclipse.jgit/src/org/eclipse/jgit/transport/UploadPack.java index afe4d3fd9f..5205ca9a9a 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/transport/UploadPack.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/transport/UploadPack.java @@ -723,7 +723,8 @@ public class UploadPack { } private boolean useProtocolV2() { - return ProtocolVersion.V2.equals(transferConfig.protocolVersion) + return (transferConfig.protocolVersion == null + || ProtocolVersion.V2.equals(transferConfig.protocolVersion)) && clientRequestedV2; } |