Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 99 for cgoUse (0.22 sec)

  1. 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)
  2. src/database/sql/sql_test.go

    	}
    	err = db.Close()
    	if err != nil {
    		t.Errorf("db Close = %v", err)
    	}
    	if !dc.closed {
    		t.Errorf("after db.Close, driverConn should be closed")
    	}
    	if n := len(dc.openStmt); n != 0 {
    		t.Errorf("driverConn num openStmt = %d; want 0", n)
    	}
    
    	err = stmt.Close()
    	if err != nil {
    		t.Errorf("Stmt close = %v", err)
    	}
    
    	if !dc.closed {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 23 18:42:28 UTC 2024
    - 111.6K bytes
    - Viewed (0)
  3. src/net/http/transport_test.go

    	tests := []struct {
    		disableKeepAlives bool
    		close             bool
    	}{
    		{disableKeepAlives: false, close: false},
    		{disableKeepAlives: false, close: true},
    		{disableKeepAlives: true, close: false},
    		{disableKeepAlives: true, close: true},
    	}
    
    	for _, tc := range tests {
    		t.Run(fmt.Sprintf("DisableKeepAlive=%v,RequestClose=%v", tc.disableKeepAlives, tc.close),
    			func(t *testing.T) {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Jun 06 21:59:21 UTC 2024
    - 192.6K bytes
    - Viewed (0)
  4. src/database/sql/sql.go

    }
    
    // Close closes the database and prevents new queries from starting.
    // Close then waits for all queries that have started processing on the server
    // to finish.
    //
    // It is rare to Close a [DB], as the [DB] handle is meant to be
    // long-lived and shared between many goroutines.
    func (db *DB) Close() error {
    	db.mu.Lock()
    	if db.closed { // Make DB.Close idempotent
    		db.mu.Unlock()
    		return nil
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 23 01:16:53 UTC 2024
    - 103.6K bytes
    - Viewed (0)
  5. src/net/http/server.go

    // onceCloseListener wraps a net.Listener, protecting it from
    // multiple Close calls.
    type onceCloseListener struct {
    	net.Listener
    	once     sync.Once
    	closeErr error
    }
    
    func (oc *onceCloseListener) Close() error {
    	oc.once.Do(oc.close)
    	return oc.closeErr
    }
    
    func (oc *onceCloseListener) close() { oc.closeErr = oc.Listener.Close() }
    
    // globalOptionsHandler responds to "OPTIONS *" requests.
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Fri Jun 07 17:57:01 UTC 2024
    - 123.4K bytes
    - Viewed (0)
  6. staging/src/k8s.io/apiserver/pkg/endpoints/apiserver_test.go

    	defer response.Body.Close()
    	body, err := ioutil.ReadAll(response.Body)
    	if err != nil {
    		return string(body), err
    	}
    	return string(body), runtime.DecodeInto(decoder, body, object)
    }
    
    func extractBodyObject(response *http.Response, decoder runtime.Decoder) (runtime.Object, string, error) {
    	defer response.Body.Close()
    	body, err := ioutil.ReadAll(response.Body)
    	if err != nil {
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Mon May 01 20:15:22 UTC 2023
    - 158.7K bytes
    - Viewed (0)
  7. pkg/kubelet/eviction/eviction_manager_test.go

    				t.Errorf("Manager chose to kill pod: %v, but should have chosen %v", podKiller.pod.Name, podToEvict.Name)
    			}
    			if podKiller.gracePeriodOverride == nil {
    				t.Errorf("Manager chose to kill pod but should have had a grace period override.")
    			}
    			observedGracePeriod = *podKiller.gracePeriodOverride
    			if observedGracePeriod != int64(1) {
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Wed May 15 23:14:12 UTC 2024
    - 119.9K bytes
    - Viewed (0)
  8. okhttp/src/test/java/okhttp3/CacheTest.kt

        testRequestMethod("GET", true)
      }
    
      @Test
      fun requestMethodHeadIsNotCached() {
        // We could support this but choose not to for implementation simplicity
        testRequestMethod("HEAD", false)
      }
    
      @Test
      fun requestMethodPostIsNotCached() {
        // We could support this but choose not to for implementation simplicity
        testRequestMethod("POST", false)
      }
    
      @Test
    Registered: Sun Jun 16 04:42:17 UTC 2024
    - Last Modified: Wed Apr 10 19:46:48 UTC 2024
    - 108.6K bytes
    - Viewed (0)
  9. okhttp/src/test/java/okhttp3/URLConnectionTest.kt

        server.enqueue(response)
        val request = newRequest("/")
        val c1 = getResponse(request)
        assertContent("ABCDE", c1, 5)
        val c2 = getResponse(request)
        assertContent("ABCDE", c2, 5)
        c1.close()
        c2.close()
      }
    
      @Test
      fun connectionsArePooled() {
        val response =
          MockResponse(
            body = "ABCDEFGHIJKLMNOPQR",
          )
        server.enqueue(response)
    Registered: Sun Jun 16 04:42:17 UTC 2024
    - Last Modified: Sat Jan 20 10:30:28 UTC 2024
    - 131.7K bytes
    - Viewed (0)
  10. src/cmd/go/internal/work/exec.go

    	if err := check(name, "#cgo "+name, fromPackage); err != nil {
    		return nil, err
    	}
    	return str.StringList(envList("CGO_"+name, defaults), fromPackage), nil
    }
    
    var cgoRe = lazyregexp.New(`[/\\:]`)
    
    func (b *Builder) cgo(a *Action, cgoExe, objdir string, pcCFLAGS, pcLDFLAGS, cgofiles, gccfiles, gxxfiles, mfiles, ffiles []string) (outGo, outObj []string, err error) {
    	p := a.Package
    	sh := b.Shell(a)
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Jun 10 14:46:37 UTC 2024
    - 105.6K bytes
    - Viewed (0)
Back to top