Allow passing mncmd to CPULimitedHost.popen()

This is not not really intended as an external API (and
it currently isn't documented) but this makes it consistent.

Fixes #743
This commit is contained in:
Bob Lantz
2017-05-22 15:36:23 -07:00
parent 69b6c05970
commit 9d306ad53a
+2 -2
View File
@@ -702,8 +702,8 @@ class CPULimitedHost( Host ):
args: Popen() args, single list, or string args: Popen() args, single list, or string
kwargs: Popen() keyword args""" kwargs: Popen() keyword args"""
# Tell mnexec to execute command in our cgroup # Tell mnexec to execute command in our cgroup
mncmd = [ 'mnexec', '-g', self.name, mncmd = kwargs.pop( 'mncmd', [ 'mnexec', '-g', self.name,
'-da', str( self.pid ) ] '-da', str( self.pid ) ] )
# if our cgroup is not given any cpu time, # if our cgroup is not given any cpu time,
# we cannot assign the RR Scheduler. # we cannot assign the RR Scheduler.
if self.sched == 'rt': if self.sched == 'rt':