diff options
author | Ivan Frade <ifrade@google.com> | 2018-10-17 16:52:30 -0700 |
---|---|---|
committer | Ivan Frade <ifrade@google.com> | 2018-10-19 16:55:56 -0700 |
commit | 8d4f8d55d3d14b51983f951568a2f4e4ff64b324 (patch) | |
tree | 6394f4bc0166e81f7553ba31f8274959925ef997 /org.eclipse.jgit/src/org/eclipse/jgit/internal/transport | |
parent | 40f5b28545989f7e200f6e0b2007459d63279103 (diff) | |
download | jgit-8d4f8d55d3d14b51983f951568a2f4e4ff64b324.tar.gz jgit-8d4f8d55d3d14b51983f951568a2f4e4ff64b324.zip |
UploadPack: Return correct peer user agent on v2 requests
UploadPack.getPeerUserAgent() doesn't produce the expected results for
protocol v2 requests. In v2, the agent reported in the request (in an
"agent=" line) is not in the clientCapabilities but in a field on its
own. This makes getPeerUserAgent default to the transport user agent.
Making "agent" a shared property between protocol v0/v1 and v2 fixes the
problem, simplifies the function and harmonizes the implementation
between protocol versions.
In a follow up commit the "agent" will be identified on parsing time,
instead of taking it from the client capabilities.
Change-Id: Idf9825ec4e0b81a1458c8e3701f3e28aafd8a32a
Signed-off-by: Ivan Frade <ifrade@google.com>
Diffstat (limited to 'org.eclipse.jgit/src/org/eclipse/jgit/internal/transport')
0 files changed, 0 insertions, 0 deletions