Skip to content

Commit 40838cb

Browse files
authored
Merge pull request #183 from molpako/fix-comment
fix: correct chunk size comment to 1 MiB
2 parents 5a86125 + 42a67a4 commit 40838cb

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

pkg/iterator/emitters.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -99,13 +99,13 @@ type VerifierEmitter struct {
9999
TargetDevice *os.File
100100
}
101101

102-
const chunkSize = int64(1024 * 1024) // 4KB
102+
const chunkSize = int64(1024 * 1024) // 1 MiB
103103
var (
104104
ErrFailedToSeek = errors.New("failed to seek")
105105
ErrContentsDoNotMatch = errors.New("source and target device contents do not match")
106106
)
107107

108-
// copyBlock will copy chunks of 256 bytes at a time upto to sizeBytes from the source device to the target device.
108+
// copyBlock will copy chunks of 1 MiB at a time upto to sizeBytes from the source device to the target device.
109109
func (verifierEmitter *VerifierEmitter) copyBlock(bmd *api.BlockMetadata) error {
110110
// Seek to the byteOffset of the source device.
111111
_, err := verifierEmitter.SourceDevice.Seek(bmd.ByteOffset, io.SeekStart)

0 commit comments

Comments
 (0)