mirror of
https://github.com/valitydev/salt.git
synced 2024-11-07 08:58:59 +00:00
Switch open()
for salt.utils.fopen()
This commit is contained in:
parent
1857a0d31f
commit
bea345e720
@ -61,8 +61,9 @@ class MasterTest(integration.ShellCase, integration.ShellCaseCommonTestsMixIn):
|
||||
|
||||
# Now kill it if still running
|
||||
if os.path.exists(pid_path):
|
||||
with salt.utils.fopen(pid_path) as fhr:
|
||||
try:
|
||||
os.kill(int(open(pid_path).read()), signal.SIGKILL)
|
||||
os.kill(int(fhr.read()), signal.SIGKILL)
|
||||
except OSError:
|
||||
pass
|
||||
try:
|
||||
|
Loading…
Reference in New Issue
Block a user