Search Options

Results per page
Sort
Preferred Languages
Advance

Results 21 - 30 of 63 for TrimSpace (0.19 sec)

  1. cni/pkg/log/uds.go

    	for _, l := range cniLogs {
    		var msg cniLog
    		if err := json.Unmarshal([]byte(l), &msg); err != nil {
    			log.Debugf("Failed to unmarshal CNI plugin log entry: %v", err)
    			continue
    		}
    		msg.Msg = strings.TrimSpace(msg.Msg)
    		messages = append(messages, msg)
    	}
    	// Lock log message printing to prevent log messages from different CNI
    	// processes interleave.
    	l.mu.Lock()
    	defer l.mu.Unlock()
    	for _, m := range messages {
    Go
    - Registered: Wed May 08 22:53:08 GMT 2024
    - Last Modified: Wed Nov 29 01:05:12 GMT 2023
    - 3.3K bytes
    - Viewed (0)
  2. cmd/leak-detect_test.go

    		// Again split on a new line, the first line of the second half contains the info about the go routine.
    		sl := strings.SplitN(g, "\n", 2)
    		if len(sl) != 2 {
    			continue
    		}
    		stack := strings.TrimSpace(sl[1])
    		// ignore the testing go routine.
    		// since the tests will be invoking the leaktest it would contain the test go routine.
    		if strings.HasPrefix(stack, "testing.RunTests") {
    			continue
    		}
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Thu Jan 18 07:03:17 GMT 2024
    - 5.2K bytes
    - Viewed (0)
  3. src/cmd/cgo/internal/swig/swig_test.go

    	// See https://golang.org/issue/23469.
    	output, err := exec.Command(swig, "-go", "-swiglib").Output()
    	if err != nil {
    		t.Skip("swig is missing Go support")
    	}
    	swigDir := strings.TrimSpace(string(output))
    
    	_, err = os.Stat(filepath.Join(swigDir, "go"))
    	if err != nil {
    		t.Skip("swig is missing Go support")
    	}
    
    	// Check that swig has a new enough version.
    Go
    - Registered: Tue Apr 23 11:13:09 GMT 2024
    - Last Modified: Fri May 12 12:00:07 GMT 2023
    - 3.7K bytes
    - Viewed (0)
  4. cmd/generic-handlers.go

    		// if the caller sends path of following style
    		// a/a/a/a/a/a/a/a...
    		return true
    	}
    	path = filepath.ToSlash(strings.TrimSpace(path)) // For windows '\' must be converted to '/'
    	for _, p := range strings.Split(path, SlashSeparator) {
    		switch strings.TrimSpace(p) {
    		case dotdotComponent:
    			return true
    		case dotComponent:
    			return true
    		}
    	}
    	return false
    }
    
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Thu Apr 11 01:08:52 GMT 2024
    - 20.7K bytes
    - Viewed (0)
  5. docs/debugging/hash-set/main.go

    		b, err := os.ReadFile(file)
    		if err != nil {
    			log.Fatalln(err)
    		}
    		b = bytes.ReplaceAll(b, []byte("\r"), []byte{})
    		sc := bufio.NewScanner(bytes.NewBuffer(b))
    		for sc.Scan() {
    			object = strings.TrimSpace(sc.Text())
    			set := sipHashMod(prefix+object, setCount, id)
    			distrib[set] = append(distrib[set], prefix+object)
    		}
    		for set, files := range distrib {
    			fmt.Println("Set:", set+1, "Objects:", len(files))
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Mon Sep 19 18:05:16 GMT 2022
    - 3.7K bytes
    - Viewed (0)
  6. internal/disk/stat_linux.go

    	if err != nil {
    		return nil, err
    	}
    	defer file.Close()
    
    	s, err := bufio.NewReader(file).ReadString('\n')
    	if err != nil && !errors.Is(err, io.EOF) {
    		return nil, err
    	}
    	statLine := strings.TrimSpace(s)
    	for _, token := range strings.Fields(statLine) {
    		ui64, err := strconv.ParseUint(token, 10, 64)
    		if err != nil {
    			return nil, err
    		}
    		stats = append(stats, ui64)
    	}
    
    	return stats, nil
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Mon Feb 26 19:34:50 GMT 2024
    - 4.8K bytes
    - Viewed (0)
  7. docs/debugging/inspect/main.go

    			reader := bufio.NewReader(os.Stdin)
    			fmt.Print("Enter Decryption Key: ")
    
    			text, _ := reader.ReadString('\n')
    			// convert CRLF to LF
    			*keyHex = strings.ReplaceAll(text, "\n", "")
    			*keyHex = strings.TrimSpace(*keyHex)
    		}
    	}
    
    	var inputFileName, outputFileName string
    
    	// Parse parameters
    	switch {
    	case *stdin:
    		// Parse 'mc support inspect --json' output
    		input := struct {
    			File string `json:"file"`
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Thu Apr 11 21:22:47 GMT 2024
    - 4.8K bytes
    - Viewed (0)
  8. cmd/server-startup-msg.go

    func printServerCommonMsg(apiEndpoints []string) {
    	// Get saved credentials.
    	cred := globalActiveCred
    
    	// Get saved region.
    	region := globalSite.Region
    
    	apiEndpointStr := strings.TrimSpace(strings.Join(apiEndpoints, "  "))
    	// Colorize the message and print.
    	logger.Info(color.Blue("API: ") + color.Bold(fmt.Sprintf("%s ", apiEndpointStr)))
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Sat Mar 09 03:07:08 GMT 2024
    - 6.8K bytes
    - Viewed (0)
  9. cmd/streaming-v4-unsigned.go

    	for k := range cr.trailers {
    		wantTrailers[strings.ToLower(k)] = struct{}{}
    	}
    	input := bufio.NewScanner(bytes.NewReader(valueBuffer.Bytes()))
    	for input.Scan() {
    		line := strings.TrimSpace(input.Text())
    		if line == "" {
    			continue
    		}
    		// Find first separator.
    		idx := strings.IndexByte(line, trailerKVSeparator[0])
    		if idx <= 0 || idx >= len(line) {
    			if cr.debug {
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Sat May 06 02:53:12 GMT 2023
    - 6.1K bytes
    - Viewed (1)
  10. cmd/bootstrap-peer-server.go

    		msg += fmt.Sprintf(`Mismatching environment values: %v. `, mismatching)
    	}
    	if len(extra) > 0 {
    		msg += fmt.Sprintf(`Extra environment values: %v. `, extra)
    	}
    
    	return errors.New(strings.TrimSpace(msg))
    }
    
    var skipEnvs = map[string]struct{}{
    	"MINIO_OPTS":          {},
    	"MINIO_CERT_PASSWD":   {},
    	"MINIO_SERVER_DEBUG":  {},
    	"MINIO_DSYNC_TRACE":   {},
    	"MINIO_ROOT_USER":     {},
    Go
    - Registered: Sun May 05 19:28:20 GMT 2024
    - Last Modified: Thu Apr 04 12:04:40 GMT 2024
    - 7.5K bytes
    - Viewed (0)
Back to top