Skip to content
This repository was archived by the owner on Jun 15, 2023. It is now read-only.

Commit e32b0dc

Browse files
committed
api/url accepts 512k torrents size
1 parent 6e2f386 commit e32b0dc

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

server/server_api.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -111,8 +111,8 @@ func (s *Server) apiPOST(r *http.Request) error {
111111
return fmt.Errorf("Invalid remote torrent URL: %s %w", url, err)
112112
}
113113
defer remote.Body.Close()
114-
if remote.ContentLength > 64*1024 {
115-
//enforce max body size (64k?)
114+
if remote.ContentLength > 512*1024 {
115+
//enforce max body size (512k)
116116
return fmt.Errorf("Remote torrent too large")
117117
}
118118
data, err = ioutil.ReadAll(remote.Body)

0 commit comments

Comments
 (0)