- Sort Score
- Result 10 results
- Languages All
Results 1 - 3 of 3 for writeDataBlocks (0.07 sec)
-
cmd/erasure-utils.go
size += len(block) } return size } // Writes all the data blocks from encoded blocks until requested // outSize length. Provides a way to skip bytes until the offset. func writeDataBlocks(ctx context.Context, dst io.Writer, enBlocks [][]byte, dataBlocks int, offset int64, length int64) (int64, error) { // Offset and out size cannot be negative. if offset < 0 || length < 0 { return 0, errUnexpected }
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Wed Jan 31 02:11:45 UTC 2024 - 3.1K bytes - Viewed (0) -
cmd/erasure_test.go
if decoded[j] == nil { t.Errorf("Test %d: failed to reconstruct data shard %d", i, j) } } } decodedData := new(bytes.Buffer) if _, err = writeDataBlocks(context.Background(), decodedData, decoded, test.dataBlocks, 0, int64(len(data))); err != nil { t.Errorf("Test %d: failed to write data blocks: %v", i, err) } if !bytes.Equal(decodedData.Bytes(), data) {
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Mon Jul 25 19:37:26 UTC 2022 - 4.8K bytes - Viewed (0) -
cmd/erasure-decode.go
// For all errors that cannot be reconstructed fail the read operation. return -1, err } if err = e.DecodeDataBlocks(bufs); err != nil { return -1, err } n, err := writeDataBlocks(ctx, writer, bufs, e.dataBlocks, blockOffset, blockLength) if err != nil { return -1, err } bytesWritten += n } if bytesWritten != length { return bytesWritten, errLessData }
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Thu Aug 29 01:40:52 UTC 2024 - 9.5K bytes - Viewed (0)