Skip to content

Commit

Permalink
fix: 修复SVN-PROXY响应的Content-Length设置错误导致SVN拉取失败 TencentBlueKing#1572 (T…
Browse files Browse the repository at this point in the history
  • Loading branch information
cnlkl authored Dec 19, 2023
1 parent 9659fdf commit 1f89a0b
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -141,9 +141,9 @@ class ChangeAncestorProxyHandler(
oldBody,
buildSearchList(oldPrefix),
buildReplacementList(newPrefix)
)
proxyResponse.setHeader(HttpHeaders.CONTENT_LENGTH, newBody.length.toString())
proxyResponse.writer.write(newBody)
).toByteArray()
proxyResponse.setContentLength(newBody.size)
proxyResponse.outputStream.write(newBody)
}
} else {
response.body?.byteStream()?.use {
Expand Down

0 comments on commit 1f89a0b

Please sign in to comment.