Skip to content
This repository has been archived by the owner on Jun 20, 2024. It is now read-only.

Commit

Permalink
set correct data block size
Browse files Browse the repository at this point in the history
  • Loading branch information
MalinAhlberg committed Feb 13, 2024
1 parent 8401724 commit 620e681
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion api/sda/sda.go
Original file line number Diff line number Diff line change
Expand Up @@ -349,7 +349,7 @@ var calculateEncryptedEndPosition = func(start, end int64, fileDetails *database
headlength := bytes.NewReader(fileDetails.Header)
bodyEnd := int64(fileDetails.ArchiveSize)
if end > 0 {
var packageSize float64 = 64000
var packageSize float64 = 65564 // 64KiB+28 but TODO 28 is for chacha20_ietf_poly1305
togo := end - start
log.Debug("headlength size: ", headlength.Size())
bodysize := math.Max(float64(togo-headlength.Size()), 0)
Expand Down

0 comments on commit 620e681

Please sign in to comment.