From: Xing Xin Date: Tue, 8 Oct 2024 03:38:17 +0000 (+0000) Subject: transport.c::handshake: make use of server options from remote X-Git-Tag: v2.48.0-rc0~121^2~2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=094f78a16a6c150ff125afd9c3f2773b47384c06;p=thirdparty%2Fgit.git transport.c::handshake: make use of server options from remote Utilize the `server_options` from the corresponding remote during the handshake in `transport.c` when Git protocol v2 is detected. This helps initialize the `server_options` in `transport.h:transport` if no server options are set for the transport (typically via `--server-option` or `-o`). While another potential place to incorporate server options from the remote is in `transport.c:transport_get`, setting server options for a transport using a protocol other than v2 could lead to unexpected errors (see `transport.c:die_if_server_options`). Relevant tests and documentation have been updated accordingly. Signed-off-by: Xing Xin Reviewed-by: Patrick Steinhardt Signed-off-by: Junio C Hamano --- diff --git a/Documentation/fetch-options.txt b/Documentation/fetch-options.txt index 80838fe37e..9dc7ac8dbd 100644 --- a/Documentation/fetch-options.txt +++ b/Documentation/fetch-options.txt @@ -305,6 +305,9 @@ endif::git-pull[] unknown ones, is server-specific. When multiple `--server-option=