mirror of
https://github.com/munki/munki.git
synced 2026-04-22 12:38:23 -05:00
Minor bug fixes and code cleanup.
git-svn-id: http://munki.googlecode.com/svn/trunk@298 a4e17f2e-e282-11dd-95e1-755cbddbdd66
This commit is contained in:
@@ -231,8 +231,8 @@ def osascript(osastring):
|
||||
print >>sys.stderr, "Error: ", err
|
||||
if out:
|
||||
return out.decode('UTF-8').rstrip("\n")
|
||||
|
||||
|
||||
|
||||
|
||||
# dmg helpers
|
||||
|
||||
def mountdmg(dmgpath):
|
||||
|
||||
@@ -97,9 +97,10 @@ def getPIDforProcessName(processname):
|
||||
if not line and (p.poll() != None):
|
||||
break
|
||||
line = line.rstrip('\n');
|
||||
(pid, proc) = line.split(None,1)
|
||||
if proc.find(processname) != -1:
|
||||
return str(pid)
|
||||
if line:
|
||||
(pid, proc) = line.split(None,1)
|
||||
if proc.find(processname) != -1:
|
||||
return str(pid)
|
||||
|
||||
return 0
|
||||
|
||||
|
||||
Reference in New Issue
Block a user