Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 3 of 3 for mayberemovefile (0.33 sec)

  1. src/cmd/go/internal/work/build_test.go

    	if err != nil {
    		t.Skip(err)
    	}
    	if fi.Mode().IsRegular() {
    		t.Errorf("Lstat(%s).Mode().IsRegular() = true; expected false", os.DevNull)
    	}
    	mayberemovefile(os.DevNull)
    	_, err = os.Lstat(os.DevNull)
    	if err != nil {
    		t.Errorf("mayberemovefile(%s) did remove it; oops", os.DevNull)
    	}
    }
    
    func TestSplitPkgConfigOutput(t *testing.T) {
    	for _, test := range []struct {
    		in   []byte
    		want []string
    	}{
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Oct 19 19:09:38 UTC 2023
    - 8.3K bytes
    - Viewed (0)
  2. src/cmd/go/internal/work/shell.go

    	_, err = io.Copy(df, sf)
    	df.Close()
    	if err != nil {
    		mayberemovefile(dst)
    		return fmt.Errorf("copying %s to %s: %v", src, dst, err)
    	}
    	return nil
    }
    
    // mayberemovefile removes a file only if it is a regular file
    // When running as a user with sufficient privileges, we may delete
    // even device files, for example, which is not intended.
    func mayberemovefile(s string) {
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu May 16 14:34:32 UTC 2024
    - 19.8K bytes
    - Viewed (0)
  3. platforms/native/platform-native/src/main/java/org/gradle/nativeplatform/toolchain/internal/tools/ToolSearchPath.java

            try {
                if (name.contains(File.separator)) {
                    return maybeResolveFile(operatingSystem, new File(name), new File(exeName));
                }
                for (File pathEntry : path) {
                    File resolved = maybeResolveFile(operatingSystem, new File(pathEntry, name), new File(pathEntry, exeName));
                    if (resolved != null) {
    Registered: Wed Jun 12 18:38:38 UTC 2024
    - Last Modified: Thu Nov 16 20:20:03 UTC 2023
    - 6.2K bytes
    - Viewed (0)
Back to top