code: func applyOOMScoreAdj(pid int, oomScoreAdj int) error {
  	if pid < 0 {
  		return fmt.Errorf("invalid PID %d specified for oom_score_adj", pid)
  	}
  
  	var pidStr string
  	if pid == 0 {
  		pidStr = "self"
  	} else {
  		pidStr = strconv.Itoa(pid)
  	}
  
  	oomScoreAdjPath := path.Join("/proc", pidStr, "oom_score_adj")
  	maxTries := 2
  	var err error
  	for i := 0; i < maxTries; i++ {
  		_, readErr := ioutil.ReadFile(oomScoreAdjPath)
  		if readErr != nil {
  			err = fmt.Errorf("failed to read oom_score_adj: %v", readErr)
  		} else if writeErr := ioutil.WriteFile(oomScoreAdjPath, []byte(strconv.Itoa(oomScoreAdj)), 0700); writeErr != nil {
  			err = fmt.Errorf("failed to set oom_score_adj to %d: %v", oomScoreAdj, writeErr)
  		} else {
  			return nil
  		}
  	}
  
  	return err
  }
docs: // Writes 'value' to /proc/<pid>/oom_score_adj. PID = 0 means self