code: func (oomAdjuster *OOMAdjuster) applyOOMScoreAdjContainer(cgroupName string, oomScoreAdj, maxTries int) error {
  	adjustedProcessSet := make(map[int]bool)
  	for i := 0; i < maxTries; i++ {
  		continueAdjusting := false
  		pidList, err := oomAdjuster.pidLister(cgroupName)
  		if err != nil {
  			continueAdjusting = true
  			glog.Errorf("Error getting process list for cgroup %s: %+v", cgroupName, err)
  		} else if len(pidList) == 0 {
  			continueAdjusting = true
  		} else {
  			for _, pid := range pidList {
  				if !adjustedProcessSet[pid] {
  					continueAdjusting = true
  					if err = oomAdjuster.ApplyOOMScoreAdj(pid, oomScoreAdj); err == nil {
  						adjustedProcessSet[pid] = true
  					}
  				}
  			}
  		}
  		if !continueAdjusting {
  			return nil
  		}
  		// There's a slight race. A process might have forked just before we write its OOM score adjust.
  		// The fork might copy the parent process's old OOM score, then this function might execute and
  		// update the parent's OOM score, but the forked process id might not be reflected in cgroup.procs
  		// for a short amount of time. So this function might return without changing the forked process's
  		// OOM score. Very unlikely race, so ignoring this for now.
  	}
  	return fmt.Errorf("exceeded maxTries, some processes might not have desired OOM score")
  }
docs: // Writes 'value' to /proc/<pid>/oom_score_adj for all processes in cgroup cgroupName.
  // Keeps trying to write until the process list of the cgroup stabilizes, or until maxTries tries.