aboutsummaryrefslogtreecommitdiff
path: root/http_handle_repo_raw.go
diff options
context:
space:
mode:
authorRunxi Yu <me@runxiyu.org>2025-04-05 13:47:00 +0800
committerRunxi Yu <me@runxiyu.org>2025-04-05 13:47:00 +0800
commit79a85ae7cbec23d9590566a3e770d8e216ea3af3 (patch)
treef4ef973286c999087fc4f0daa5e557f8f40d3cf6 /http_handle_repo_raw.go
parentHTTP: Use range in for loops over integers (diff)
downloadforge-0.1.19.tar.gz
forge-0.1.19.tar.zst
forge-0.1.19.zip
Be a bit more careful handling size integer overflows and suchv0.1.19
Diffstat (limited to 'http_handle_repo_raw.go')
-rw-r--r--http_handle_repo_raw.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/http_handle_repo_raw.go b/http_handle_repo_raw.go
index 835dd1b..8a9740e 100644
--- a/http_handle_repo_raw.go
+++ b/http_handle_repo_raw.go
@@ -100,7 +100,7 @@ func httpHandleRepoRaw(writer http.ResponseWriter, request *http.Request, params
files = append(files, displayTreeEntry{
Name: string(name),
Mode: fmt.Sprintf("%06o", mode),
- Size: int64(size),
+ Size: size,
IsFile: typeCode == 2,
IsSubtree: typeCode == 1,
})