Search Options

Results per page
Sort
Preferred Languages
Advance

Results 71 - 80 of 1,847 for closeFD (0.21 sec)

  1. okhttp/src/test/java/okhttp3/internal/cache2/RelayTest.kt

        val relay = edit(file, upstream, metadata, 1024)
        val source1 = relay.newSource()
        val source2 = relay.newSource()
        source1!!.close()
        source1.close() // Unnecessary. Shouldn't decrement the reference count.
        assertThat(relay.isClosed).isFalse()
        source2!!.close()
        assertThat(relay.isClosed).isTrue()
        assertFile(Relay.PREFIX_DIRTY, -1L, -1, null, null)
      }
    
      @Test
      fun racingReaders() {
    Registered: Sun Jun 16 04:42:17 UTC 2024
    - Last Modified: Thu Apr 11 22:09:35 UTC 2024
    - 8.1K bytes
    - Viewed (0)
  2. pkg/test/echo/server/forwarder/http.go

    			QUICConfig:      &quic.Config{},
    		}
    	}
    	closeFn := func(conn *http3.RoundTripper) func() {
    		return func() {
    			_ = conn.Close()
    		}
    	}
    	noCloseFn := func() {}
    
    	if cfg.newConnectionPerRequest {
    		// Create a new transport (i.e. connection) for each request.
    		return func() (http.RoundTripper, func(), error) {
    			conn := newConn()
    			return conn, closeFn(conn), nil
    		}, noCloseFn
    	}
    
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Tue Apr 30 13:56:46 UTC 2024
    - 7.9K bytes
    - Viewed (0)
  3. src/internal/xcoff/ar.go

    	}
    	arch, err := NewArchive(f)
    	if err != nil {
    		f.Close()
    		return nil, err
    	}
    	arch.closer = f
    	return arch, nil
    }
    
    // Close closes the Archive.
    // If the Archive was created using NewArchive directly instead of OpenArchive,
    // Close has no effect.
    func (a *Archive) Close() error {
    	var err error
    	if a.closer != nil {
    		err = a.closer.Close()
    		a.closer = nil
    	}
    	return err
    }
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Mar 04 17:32:51 UTC 2024
    - 5.6K bytes
    - Viewed (0)
  4. pkg/config/crd/validator.go

    	crds := []apiextensions.CustomResourceDefinition{}
    	closers := make([]io.Closer, 0, len(files))
    	defer func() {
    		for _, closer := range closers {
    			closer.Close()
    		}
    	}()
    	for _, file := range files {
    		data, err := os.Open(file)
    		if err != nil {
    			return nil, fmt.Errorf("failed to read input yaml file: %v", err)
    		}
    		closers = append(closers, data)
    
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Tue Oct 17 15:38:40 UTC 2023
    - 8.3K bytes
    - Viewed (0)
  5. src/internal/fuzz/sys_posix.go

    	return &sharedMem{f: f, region: region, removeOnClose: removeOnClose}, nil
    }
    
    // Close unmaps the shared memory and closes the temporary file. If this
    // sharedMem was created with sharedMemTempFile, Close also removes the file.
    func (m *sharedMem) Close() error {
    	// Attempt all operations, even if we get an error for an earlier operation.
    	// os.File.Close may fail due to I/O errors, but we still want to delete
    	// the temporary file.
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Jan 12 19:47:40 UTC 2022
    - 4.1K bytes
    - Viewed (0)
  6. src/database/sql/driver/driver.go

    // used by multiple goroutines concurrently.
    type Stmt interface {
    	// Close closes the statement.
    	//
    	// As of Go 1.1, a Stmt will not be closed if it's in use
    	// by any queries.
    	//
    	// Drivers must ensure all network calls made by Close
    	// do not block indefinitely (e.g. apply a timeout).
    	Close() error
    
    	// NumInput returns the number of placeholder parameters.
    	//
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Oct 23 09:04:12 UTC 2023
    - 20.9K bytes
    - Viewed (0)
  7. src/net/http/serve_test.go

    			}
    			t.Cleanup(func() { bresp.Body.Close() })
    
    			// Try to cause a race. Canceling the client request will cause the client
    			// transport to close req2.Body. Returning from the server handler will
    			// cause the server to close req.Body. Since they are the same underlying
    			// ReadCloser, that will result in concurrent calls to Close (and possibly a
    			// Read concurrent with a Close).
    			if mode == http2Mode {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Jun 07 17:57:01 UTC 2024
    - 202K bytes
    - Viewed (0)
  8. subprojects/diagnostics/src/main/resources/org/gradle/api/tasks/diagnostics/htmldependencyreport/script.js

                    $tree.append($('<p/>').text("No dependency"));
                }
    
                $tree.on('click', 'a', function(event) {
                    event.preventDefault();
                    var module = $(this).closest('li').attr('data-module');
                    showModuleInsight(module, configuration.moduleInsights);
                });
    
                $configurationDiv.append($contentDiv);
                $dependencies.append($configurationDiv);
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Mon Aug 24 19:38:03 UTC 2020
    - 8.2K bytes
    - Viewed (0)
  9. 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)
  10. pkg/kube/multicluster/cluster.go

    	// In this case, the `initialSyncTimeout` will never be set
    	// In order not block istiod start up, check close as well.
    	if c.Closed() {
    		return true
    	}
    	return c.initialSync.Load() || c.initialSyncTimeout.Load()
    }
    
    func (c *Cluster) Closed() bool {
    	select {
    	case <-c.stop:
    		return true
    	default:
    		return false
    	}
    }
    
    func (c *Cluster) SyncDidTimeout() bool {
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Wed Mar 06 02:13:10 UTC 2024
    - 3.8K bytes
    - Viewed (0)
Back to top