- Sort Score
- Num 10 results
- Language All
Results 1 - 10 of 12 for readerFor (0.15 seconds)
-
internal/s3select/jstream/errors.go
msg string // description of error context string // additional error context pos errPos atChar byte readerErr error // underlying reader error, if any } // ReaderErr returns the underlying error. func (e DecoderError) ReaderErr() error { return e.readerErr } // Error returns a string representation of the error. func (e DecoderError) Error() string {Created: Sun Apr 05 19:28:12 GMT 2026 - Last Modified: Mon Sep 23 19:35:41 GMT 2024 - 1.3K bytes - Click Count (0) -
internal/ringbuffer/ring_buffer_test.go
// Reader var readErr error var wg sync.WaitGroup wg.Add(1) go func() { defer wg.Done() defer rb.CloseWithError(readErr) readRng := rand.New(rand.NewSource(1)) buf := make([]byte, 64<<10) for { // Read n, err := rb.Read(buf[:readRng.Intn(len(buf))]) readBytes += n read.Write(buf[:n]) if err != nil { readErr = err break }
Created: Sun Apr 05 19:28:12 GMT 2026 - Last Modified: Fri Aug 29 02:39:48 GMT 2025 - 26.7K bytes - Click Count (0) -
internal/s3select/jstream/scanner_test.go
var i int r := bytes.NewReader(data) scanner := newScanner(r) for scanner.pos < atomic.LoadInt64(&scanner.end) { c := scanner.next() if scanner.readerErr != nil { t.Fatal(scanner.readerErr) } if c != data[i] { t.Fatalf("expected %s, got %s", string(data[i]), string(c)) } t.Logf("pos=%d remaining=%d (%s)", i, r.Len(), string(c)) i++ } }
Created: Sun Apr 05 19:28:12 GMT 2026 - Last Modified: Fri Aug 29 02:39:48 GMT 2025 - 3.1K bytes - Click Count (0) -
internal/s3select/jstream/scanner.go
end int64 buf [chunk + 1]byte // internal buffer (with a lookback size of 1) nbuf [chunk]byte // next internal buffer fillReq chan struct{} fillReady chan int64 readerErr error // underlying reader error, if any } func newScanner(r io.Reader) *scanner { sr := &scanner{ end: maxInt, fillReq: make(chan struct{}), fillReady: make(chan int64), } go func() {
Created: Sun Apr 05 19:28:12 GMT 2026 - Last Modified: Mon Sep 23 19:35:41 GMT 2024 - 2.5K bytes - Click Count (0) -
internal/ringbuffer/ring_buffer.go
if len(p) == 0 { return 0, r.readErr(false) } r.mu.Lock() defer r.mu.Unlock() if err := r.readErr(true); err != nil { return 0, err } r.wg.Add(1) defer r.wg.Done() n, err = r.read(p) for err == ErrIsEmpty && r.block { r.writeCond.Wait() if err = r.readErr(true); err != nil { break } n, err = r.read(p) }
Created: Sun Apr 05 19:28:12 GMT 2026 - Last Modified: Sun Sep 28 20:59:21 GMT 2025 - 13.3K bytes - Click Count (0) -
src/bufio/bufio.go
func (b *Reader) Read(p []byte) (n int, err error) { n = len(p) if n == 0 { if b.Buffered() > 0 { return 0, nil } return 0, b.readErr() } if b.r == b.w { if b.err != nil { return 0, b.readErr() } if len(p) >= len(b.buf) { // Large read, empty buffer. // Read directly into p to avoid copy. n, b.err = b.rd.Read(p) if n < 0 {
Created: Tue Apr 07 11:13:11 GMT 2026 - Last Modified: Fri Feb 06 17:28:40 GMT 2026 - 22K bytes - Click Count (0) -
cmd/metacache-stream_test.go
if err != io.EOF { t.Fatal(err) } } func Test_metacacheReader_readAll(t *testing.T) { r := loadMetacacheSample(t) defer r.Close() var readErr error objs := make(chan metaCacheEntry, 1) var wg sync.WaitGroup wg.Add(1) go func() { readErr = r.readAll(t.Context(), objs) wg.Done() }() want := loadMetacacheSampleNames i := 0 for entry := range objs { if entry.name != want[i] {Created: Sun Apr 05 19:28:12 GMT 2026 - Last Modified: Wed Apr 09 14:28:39 GMT 2025 - 15K bytes - Click Count (0) -
cmd/erasure-healing.go
return found < notFound && found > 0 } func danglingMetaErrsCount(cerrs []error) (notFoundCount int, nonActionableCount int) { for _, readErr := range cerrs { if readErr == nil { continue } switch { case errors.Is(readErr, errFileNotFound) || errors.Is(readErr, errFileVersionNotFound): notFoundCount++ default: // All other errors are non-actionable nonActionableCount++ } }
Created: Sun Apr 05 19:28:12 GMT 2026 - Last Modified: Sun Sep 28 20:59:21 GMT 2025 - 34.7K bytes - Click Count (0) -
internal/s3select/jstream/decoder.go
Created: Sun Apr 05 19:28:12 GMT 2026 - Last Modified: Fri Aug 29 02:39:48 GMT 2025 - 13.4K bytes - Click Count (0) -
internal/s3select/jstream/decoder_test.go
if err == nil { t.Fatalf("missing expected decoder error") } derr, ok := err.(DecoderError) if !ok { t.Fatalf("expected error of type DecoderError, got %T", err) } if derr.ReaderErr() == nil { t.Fatalf("missing expected underlying reader error") } } func TestDecoderMaxDepth(t *testing.T) { tests := []struct { input string maxDepth int mustFail bool }{Created: Sun Apr 05 19:28:12 GMT 2026 - Last Modified: Fri Aug 29 02:39:48 GMT 2025 - 6.6K bytes - Click Count (0)