- Sort Score
- Result 10 results
- Languages All
Results 1 - 3 of 3 for CopyAligned (0.14 sec)
-
internal/ioutil/ioutil_test.go
written, err := CopyAligned(f, io.LimitReader(r, 5), *bufp, r.Size(), f) if !errors.Is(err, io.ErrUnexpectedEOF) { t.Errorf("Expected io.ErrUnexpectedEOF, but got %v", err) } if written != 5 { t.Errorf("Expected written to be '5', but got %v", written) } f.Seek(0, io.SeekStart) r.Seek(0, io.SeekStart) written, err = CopyAligned(f, r, *bufp, r.Size(), f) if !errors.Is(err, nil) {
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Wed May 22 23:07:14 UTC 2024 - 5.5K bytes - Viewed (0) -
internal/ioutil/ioutil.go
} // DirectioAlignSize - DirectIO alignment needs to be 4K. Defined here as // directio.AlignSize is defined as 0 in MacOS causing divide by 0 error. const DirectioAlignSize = 4096 // CopyAligned - copies from reader to writer using the aligned input // buffer, it is expected that input buffer is page aligned to // 4K page boundaries. Without passing aligned buffer may cause // this function to return error. //
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Fri Jul 26 12:55:01 UTC 2024 - 10.9K bytes - Viewed (0) -
cmd/xl-storage.go
default: bufp = xioutil.ODirectPoolLarge.Get().(*[]byte) defer xioutil.ODirectPoolLarge.Put(bufp) } var written int64 if odirectEnabled { written, err = xioutil.CopyAligned(diskHealthWriter(ctx, w), r, *bufp, fileSize, w) } else { written, err = io.CopyBuffer(diskHealthWriter(ctx, w), r, *bufp) } if err != nil { w.Close() return err }
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Sat Oct 26 09:58:27 UTC 2024 - 91.3K bytes - Viewed (0)