From ea1a74626e5dc4f4289d5ad68c6c6e5adab87e7b Mon Sep 17 00:00:00 2001 From: Vincent Tavernier Date: Wed, 5 Apr 2023 23:04:50 +0200 Subject: [PATCH] Fix smart HTTP transport protocol handling This fixes the smart HTTP transport implementation receive pack service to send requests to `/git-receive-pack` instead of `/info/Refs?service=git-upload-pack`. --- http.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/http.go b/http.go index ce6b8fc..dc1a3dc 100644 --- a/http.go +++ b/http.go @@ -89,7 +89,7 @@ func (t *httpSmartSubtransport) Action(url string, action SmartServiceAction) (S req, err = http.NewRequest("GET", url+"/info/refs?service=git-receive-pack", nil) case SmartServiceActionReceivepack: - req, err = http.NewRequest("POST", url+"/info/refs?service=git-upload-pack", nil) + req, err = http.NewRequest("POST", url+"/git-receive-pack", nil) if err != nil { break }