- Sort Score
- Result 10 results
- Languages All
Results 41 - 50 of 1,753 for closeFn (0.12 sec)
-
src/mime/quotedprintable/writer.go
if n == len(p) { return n, nil } if err := w.write(p[n:]); err != nil { return n, err } return len(p), nil } // Close closes the [Writer], flushing any unwritten data to the underlying // [io.Writer], but does not close the underlying io.Writer. func (w *Writer) Close() error { if err := w.checkLastByte(); err != nil { return err } return w.flush() }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu Mar 21 16:12:35 UTC 2024 - 3.2K bytes - Viewed (0) -
pkg/kubelet/cm/dra/plugin/client_test.go
func setupFakeGRPCServer(version string) (string, tearDown, error) { p, err := os.MkdirTemp("", "dra_plugin") if err != nil { return "", nil, err } closeCh := make(chan struct{}) addr := filepath.Join(p, "server.sock") teardown := func() { close(closeCh) os.RemoveAll(addr) } listener, err := net.Listen("unix", addr) if err != nil { teardown() return "", nil, err } s := grpc.NewServer()
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Fri Apr 19 16:27:05 UTC 2024 - 8.1K bytes - Viewed (0) -
staging/src/k8s.io/apiserver/plugin/pkg/audit/buffered/buffered.go
// - Timer has passed. // - Buffer channel is closed and empty. // - stopCh is closed. func (b *bufferedBackend) collectEvents(timer <-chan time.Time, stopCh <-chan struct{}) []*auditinternal.Event { var events []*auditinternal.Event L: for i := 0; i < b.maxBatchSize; i++ { select { case ev, ok := <-b.buffer: // Buffer channel was closed and no new events will follow. if !ok { break L
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Tue Jul 26 17:14:05 UTC 2022 - 9.1K bytes - Viewed (0) -
src/net/rpc/client_test.go
codec := &shutdownCodec{responded: make(chan int)} client := NewClientWithCodec(codec) <-codec.responded client.Close() if !codec.closed { t.Error("client.Close did not close codec") } } // Test that errors in gob shut down the connection. Issue 7689. type R struct { msg []byte // Not exported, so R does not work with gob. } type S struct{} func (s *S) Recv(nul *struct{}, reply *R) error {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon Dec 13 18:45:54 UTC 2021 - 1.7K bytes - Viewed (0) -
src/runtime/stubs2.go
"unsafe" ) // read calls the read system call. // It returns a non-negative number of bytes written or a negative errno value. func read(fd int32, p unsafe.Pointer, n int32) int32 func closefd(fd int32) int32 func exit(code int32) func usleep(usec uint32) //go:nosplit func usleep_no_g(usec uint32) { usleep(usec) } // write1 calls the write system call.
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon Mar 25 19:53:03 UTC 2024 - 1.1K bytes - Viewed (0) -
src/net/http/transport_internal_test.go
t.Errorf("roundTrip = %#v, %v; want errServerClosedIdle, transportReadFromServerError, or nothingWrittenError", err, err) } <-pc.closech err = pc.closed if !isNothingWrittenError(err) && !isTransportReadFromServerError(err) && err != errServerClosedIdle { t.Errorf("pc.closed = %#v, %v; want errServerClosedIdle or transportReadFromServerError, or nothingWrittenError", err, err) } }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 16 15:57:17 UTC 2024 - 6.2K bytes - Viewed (0) -
okhttp/src/main/kotlin/okhttp3/internal/cache/DiskLruCache.kt
if (civilizedFileSystem) return fileSource lockingSourceCount++ return object : ForwardingSource(fileSource) { private var closed = false override fun close() { super.close() if (!closed) { closed = true synchronized(this@DiskLruCache) { lockingSourceCount-- if (lockingSourceCount == 0 && zombie) {
Registered: Sun Jun 16 04:42:17 UTC 2024 - Last Modified: Mon Jan 08 01:13:22 UTC 2024 - 34.7K bytes - Viewed (0) -
staging/src/k8s.io/apimachinery/pkg/util/wait/wait_test.go
t.Errorf("Until did not return immediately when the stop chan was closed inside the func") } } func TestJitterUntil(t *testing.T) { ch := make(chan struct{}) // if a channel is closed JitterUntil never calls function f // and returns immediately close(ch) JitterUntil(func() { t.Fatal("should not have been invoked") }, 0, 1.0, true, ch) ch = make(chan struct{}) called := make(chan struct{})
Registered: Sat Jun 15 01:39:40 UTC 2024 - Last Modified: Tue Mar 26 16:28:45 UTC 2024 - 41.1K bytes - Viewed (0) -
test/typeparam/chans.go
// This will leave a goroutine running until either both channels are closed // or the context is canceled, at which point the returned channel is closed. func _Merge[Elem any](ctx context.Context, c1, c2 <-chan Elem) <-chan Elem { r := make(chan Elem) go func(ctx context.Context, c1, c2 <-chan Elem, r chan<- Elem) { defer close(r) for c1 != nil || c2 != nil { select { case <-ctx.Done(): return
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue Mar 01 19:45:34 UTC 2022 - 8.4K bytes - Viewed (0) -
src/internal/poll/fd_unix.go
} // Close closes the FD. The underlying file descriptor is closed by the // destroy method when there are no remaining references. func (fd *FD) Close() error { if !fd.fdmu.increfAndClose() { return errClosing(fd.isFile) } // Unblock any I/O. Once it all unblocks and returns, // so that it cannot be referring to fd.sysfd anymore, // the final decref will close fd.sysfd. This should happen
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Fri May 31 04:09:44 UTC 2024 - 17.9K bytes - Viewed (0)