Fix some trivial problems (#34579) (#34585)
Some checks are pending
release-nightly / nightly-binary (push) Waiting to run
release-nightly / nightly-docker-rootful (push) Waiting to run
release-nightly / nightly-docker-rootless (push) Waiting to run

Backport #34579 by wxiaoguang

See the comments

Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
This commit is contained in:
Giteabot
2025-06-03 01:31:35 +08:00
committed by GitHub
parent f9a0b077a7
commit 7baa6fa47c
8 changed files with 46 additions and 12 deletions

View File

@ -721,7 +721,7 @@ func serveBlob(ctx *context.Context, pfd *packages_model.PackageFileDescriptor)
if u != nil {
headers.Status = http.StatusTemporaryRedirect
headers.Location = u.String()
headers.ContentLength = 0 // do not set Content-Length for redirect responses
setResponseHeaders(ctx.Resp, headers)
return
}