Search Options

Results per page
Sort
Preferred Languages
Advance

Results 31 - 40 of 172 for O_WRONLY (0.1 sec)

  1. tools/istio-iptables/pkg/dependencies/stub.go

    func (s *DependenciesStub) writeAllToDryRunPath() error {
    	path := DryRunFilePath.Get()
    	if path != "" {
    		// Print the input into the given output file.
    		f, err := os.OpenFile(path, os.O_CREATE|os.O_WRONLY, 0o644)
    		if err != nil {
    			return fmt.Errorf("unable to open dry run output file %v: %v", path, err)
    		}
    
    		defer f.Close()
    
    		for _, line := range s.ExecutedAll {
    			_, err := f.WriteString(line + "\n")
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Mon Mar 11 17:46:23 UTC 2024
    - 3.4K bytes
    - Viewed (0)
  2. src/runtime/export_unix_test.go

    	b := byte(0)
    	write(uintptr(waitForSigusr1.wrpipe), noescape(unsafe.Pointer(&b)), 1)
    	return true
    }
    
    // SendSigusr1 sends SIGUSR1 to mp.
    func SendSigusr1(mp *M) {
    	signalM(mp, _SIGUSR1)
    }
    
    const (
    	O_WRONLY = _O_WRONLY
    	O_CREAT  = _O_CREAT
    	O_TRUNC  = _O_TRUNC
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Sat May 20 21:27:51 UTC 2023
    - 2.3K bytes
    - Viewed (0)
  3. src/os/exec_plan9.go

    	}
    
    	return newPIDProcess(pid), nil
    }
    
    func (p *Process) writeProcFile(file string, data string) error {
    	f, e := OpenFile("/proc/"+itoa.Itoa(p.Pid)+"/"+file, O_WRONLY, 0)
    	if e != nil {
    		return e
    	}
    	defer f.Close()
    	_, e = f.Write([]byte(data))
    	return e
    }
    
    func (p *Process) signal(sig Signal) error {
    	switch p.pidStatus() {
    	case statusDone:
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Jun 10 22:06:47 UTC 2024
    - 3.4K bytes
    - Viewed (0)
  4. src/cmd/go/internal/lockedfile/mutex.go

    func (mu *Mutex) Lock() (unlock func(), err error) {
    	if mu.Path == "" {
    		panic("lockedfile.Mutex: missing Path during Lock")
    	}
    
    	// We could use either O_RDWR or O_WRONLY here. If we choose O_RDWR and the
    	// file at mu.Path is write-only, the call to OpenFile will fail with a
    	// permission error. That's actually what we want: if we add an RLock method
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Apr 03 17:17:40 UTC 2019
    - 2.3K bytes
    - Viewed (0)
  5. src/main/java/jcifs/smb1/smb1/SmbFileOutputStream.java

        public SmbFileOutputStream( SmbFile file, boolean append ) throws SmbException, MalformedURLException, UnknownHostException {
            this( file, append, append ? SmbFile.O_CREAT | SmbFile.O_WRONLY | SmbFile.O_APPEND :
                                        SmbFile.O_CREAT | SmbFile.O_WRONLY | SmbFile.O_TRUNC );
        }
    /**
     * Creates an {@link java.io.OutputStream} for writing bytes to a file
     * on an SMB server addressed by the <code>SmbFile</code> parameter. See
    Registered: Wed Jun 12 15:45:55 UTC 2024
    - Last Modified: Fri Mar 22 21:10:40 UTC 2019
    - 9.2K bytes
    - Viewed (0)
  6. cmd/prune-junit-xml/prunexml.go

    		if err != nil {
    			panic(err)
    		}
    
    		pruneXML(suites, *maxTextSize*1e6) // convert MB into bytes (roughly!)
    		if *pruneTests {
    			pruneTESTS(suites)
    		}
    
    		xmlWriter, err := os.OpenFile(path, os.O_WRONLY|os.O_CREATE|os.O_TRUNC, 0666)
    		if err != nil {
    			panic(err)
    		}
    		defer xmlWriter.Close()
    		err = streamXML(xmlWriter, suites)
    		if err != nil {
    			panic(err)
    		}
    		fmt.Println("done.")
    	}
    }
    
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Tue Jun 06 12:26:00 UTC 2023
    - 4.4K bytes
    - Viewed (0)
  7. src/os/signal/signal_plan9_test.go

    		case <-time.After(100 * time.Millisecond):
    			// nothing to read - good
    		}
    	}
    }
    
    func postNote(pid int, note string) error {
    	f, err := os.OpenFile("/proc/"+itoa.Itoa(pid)+"/note", os.O_WRONLY, 0)
    	if err != nil {
    		return err
    	}
    	defer f.Close()
    	_, err = f.Write([]byte(note))
    	return err
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Sun Mar 14 17:56:50 UTC 2021
    - 3.6K bytes
    - Viewed (0)
  8. pkg/file/file.go

    	if err != nil {
    		return err
    	}
    	defer in.Close()
    
    	perm, err := in.Stat()
    	if err != nil {
    		return err
    	}
    
    	out, err := os.OpenFile(filepath.Join(targetDir, targetFilename), os.O_WRONLY|os.O_CREATE|os.O_TRUNC, perm.Mode())
    	if err != nil {
    		return err
    	}
    	defer out.Close()
    
    	if _, err := io.Copy(out, in); err != nil {
    		return err
    	}
    	return nil
    }
    
    Registered: Fri Jun 14 15:00:06 UTC 2024
    - Last Modified: Thu Apr 11 21:42:29 UTC 2024
    - 3K bytes
    - Viewed (0)
  9. src/main/java/jcifs/smb/SmbFileOutputStream.java

            this(
                file,
                append,
                append ? SmbConstants.O_CREAT | SmbConstants.O_WRONLY | SmbConstants.O_APPEND
                        : SmbConstants.O_CREAT | SmbConstants.O_WRONLY | SmbConstants.O_TRUNC,
                0,
                SmbConstants.DEFAULT_SHARING);
        }
    
    
    Registered: Wed Jun 12 15:45:55 UTC 2024
    - Last Modified: Sat Nov 13 15:14:04 UTC 2021
    - 11.9K bytes
    - Viewed (0)
  10. src/runtime/write_err_android.go

    			clear(dst)
    			writePos = 0
    		}
    	}
    }
    
    func initLegacy() {
    	// In legacy mode, logs are written to /dev/log/main
    	writeFD = uintptr(open(&writePath[0], 0x1 /* O_WRONLY */, 0))
    	if writeFD == 0 {
    		// It is hard to do anything here. Write to stderr just
    		// in case user has root on device and has run
    		//	adb shell setprop log.redirect-stdio true
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Mar 27 18:23:49 UTC 2024
    - 4.7K bytes
    - Viewed (0)
Back to top