pylint cleanup

git-svn-id: http://munki.googlecode.com/svn/trunk@656 a4e17f2e-e282-11dd-95e1-755cbddbdd66
This commit is contained in:
Greg Neagle
2010-08-04 23:05:05 +00:00
parent c05fd84372
commit aa07c5a726
+5 -4
View File
@@ -38,10 +38,11 @@ import subprocess
def valid_plist(path):
'''Uses plutil to check a plist for validity'''
cmd = ['/usr/bin/plutil', '-lint', '-s' , path]
p = subprocess.Popen(cmd, shell=False, bufsize=1, stdin=subprocess.PIPE,
stdout=subprocess.PIPE, stderr=subprocess.PIPE)
(out, err) = p.communicate()
if p.returncode == 0:
proc = subprocess.Popen(cmd, shell=False, bufsize=1,
stdin=subprocess.PIPE,
stdout=subprocess.PIPE, stderr=subprocess.PIPE)
(out, err) = proc.communicate()
if proc.returncode == 0:
return True
else:
return False