Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 44 for discord (0.25 sec)

  1. src/bufio/bufio.go

    			err = ErrBufferFull
    		}
    	}
    	return b.buf[b.r : b.r+n], err
    }
    
    // Discard skips the next n bytes, returning the number of bytes discarded.
    //
    // If Discard skips fewer than n bytes, it also returns an error.
    // If 0 <= n <= b.Buffered(), Discard is guaranteed to succeed without
    // reading from the underlying io.Reader.
    func (b *Reader) Discard(n int) (discarded int, err error) {
    	if n < 0 {
    		return 0, ErrNegativeCount
    	}
    Go
    - Registered: Tue Apr 23 11:13:09 GMT 2024
    - Last Modified: Thu Oct 12 14:39:08 GMT 2023
    - 21.8K bytes
    - Viewed (0)
  2. src/archive/tar/reader.go

    	// one or more "header files" until it finds a "normal file".
    	format := FormatUSTAR | FormatPAX | FormatGNU
    	for {
    		// Discard the remainder of the file and any padding.
    		if err := discard(tr.r, tr.curr.physicalRemaining()); err != nil {
    			return nil, err
    		}
    		if _, err := tryReadFull(tr.r, tr.blk[:tr.pad]); err != nil {
    			return nil, err
    		}
    		tr.pad = 0
    
    Go
    - Registered: Tue Apr 23 11:13:09 GMT 2024
    - Last Modified: Fri Mar 08 01:59:14 GMT 2024
    - 26.8K bytes
    - Viewed (0)
  3. src/archive/tar/tar_test.go

    		for _, v := range vectors {
    			b.Run(v.label, func(b *testing.B) {
    				b.ReportAllocs()
    				for i := 0; i < b.N; i++ {
    					// Writing to io.Discard because we want to
    					// test purely the writer code and not bring in disk performance into this.
    					tw := NewWriter(io.Discard)
    					for _, file := range v.files {
    						if err := tw.WriteHeader(file.hdr); err != nil {
    							b.Errorf("unexpected WriteHeader error: %v", err)
    Go
    - Registered: Tue Apr 23 11:13:09 GMT 2024
    - Last Modified: Fri Mar 15 16:01:50 GMT 2024
    - 24K bytes
    - Viewed (0)
  4. cmd/metacache.go

    	if m == nil {
    		return false
    	}
    	cache := m
    	switch {
    	case !cache.finished() && time.Since(cache.lastUpdate) > metacacheMaxRunningAge:
    		// Not finished and update for metacacheMaxRunningAge, discard it.
    		return false
    	case cache.finished() && time.Since(cache.lastHandout) > 5*metacacheMaxClientWait:
    		// Keep for 15 minutes after we last saw the client.
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Thu Apr 04 12:04:40 GMT 2024
    - 5K bytes
    - Viewed (0)
  5. cni/pkg/nodeagent/informers.go

    			//
    			// If we get to this point and have a pod that really and truly has no IP in either of those,
    			// it's not routable at this point and something is wrong/we should discard this event.
    			podIPs := util.GetPodIPsIfPresent(pod)
    			if len(podIPs) == 0 {
    				log.Warnf("pod %s does not appear to have any assigned IPs, not capturing", pod.Name)
    				return nil
    			}
    
    Go
    - Registered: Wed Apr 24 22:53:08 GMT 2024
    - Last Modified: Thu Feb 08 01:03:24 GMT 2024
    - 9.9K bytes
    - Viewed (0)
  6. cmd/perf-tests.go

    						errOnce.Do(func() {
    							retError = err.Error()
    						})
    					}
    					downloadsCancel()
    					return
    				}
    				fbr := firstByteRecorder{
    					r: r,
    				}
    				n, err := xioutil.Copy(xioutil.Discard, &fbr)
    				r.Close()
    				if err == nil {
    					response := time.Since(t)
    					ttfb := time.Since(*fbr.t)
    					// Only capture success criteria - do not
    					// have to capture failed reads, truncated
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Sun Jan 28 18:04:17 GMT 2024
    - 11.3K bytes
    - Viewed (0)
  7. cmd/admin-handlers-users_test.go

    	r, err := client.GetObject(ctx, bucket, object, minio.GetObjectOptions{})
    	if err != nil {
    		c.Fatalf("user was unable to download the object: %v", err)
    	}
    	defer r.Close()
    
    	_, err = io.Copy(io.Discard, r)
    	if err != nil {
    		c.Fatalf("user was unable to download the object: %v", err)
    	}
    }
    
    func (c *check) mustHeadObject(ctx context.Context, client *minio.Client, bucket, object string, tagCount int) {
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Mon Feb 12 16:36:16 GMT 2024
    - 45.7K bytes
    - Viewed (0)
  8. cmd/admin-handlers.go

    	enc := json.NewEncoder(w)
    	if err := enc.Encode(madmin.ClientPerfExtraTime{TimeSpent: atomic.LoadInt64(&globalLastClientPerfExtraTime)}); err != nil {
    		return
    	}
    }
    
    // ClientDevNull - everything goes to io.Discard
    // [POST] /minio/admin/v3/speedtest/client/devnull
    func (a adminAPIHandlers) ClientDevNull(w http.ResponseWriter, r *http.Request) {
    	ctx := r.Context()
    
    	timeStart := time.Now()
    Go
    - Registered: Sun Apr 28 19:28:10 GMT 2024
    - Last Modified: Sun Apr 21 11:43:18 GMT 2024
    - 97.3K bytes
    - Viewed (2)
  9. src/archive/tar/writer_test.go

    	}, {
    		name: "PAX header too long",
    		h:    &Header{PAXRecords: map[string]string{"GOLANG.x": strings.Repeat("a", maxSpecialFileSize)}},
    	}} {
    		w := NewWriter(io.Discard)
    		if err := w.WriteHeader(test.h); err != ErrFieldTooLong {
    			t.Errorf("%v: w.WriteHeader() = %v, want ErrFieldTooLong", test.name, err)
    		}
    	}
    }
    
    Go
    - Registered: Tue Apr 23 11:13:09 GMT 2024
    - Last Modified: Tue Feb 27 16:39:23 GMT 2024
    - 38.7K bytes
    - Viewed (0)
  10. internal/ioutil/discard.go

    import (
    	"io"
    )
    
    // Discard is just like io.Discard without the io.ReaderFrom compatible
    // implementation which is buggy on NUMA systems, we have to use a simpler
    // io.Writer implementation alone avoids also unnecessary buffer copies,
    // and as such incurred latencies.
    var Discard io.Writer = discard{}
    
    // discard is /dev/null for Golang.
    type discard struct{}
    
    func (discard) Write(p []byte) (int, error) {
    Go
    - Registered: Sun Apr 21 19:28:08 GMT 2024
    - Last Modified: Mon Nov 06 22:26:08 GMT 2023
    - 1.3K bytes
    - Viewed (0)
Back to top