Set world-readable permissions on alert file

Change-Id: Iaaea474d064479b2732deddd124fba02670ca4d8
This commit is contained in:
James E. Blair 2013-12-11 14:34:20 -08:00
parent ab953f9fdc
commit a104892265
1 changed files with 1 additions and 0 deletions

View File

@ -166,6 +166,7 @@ class AlertFile(UpdateInterface):
f, path = tempfile.mkstemp(dir=self.dir)
os.write(f, json.dumps(dict(alert=msg)))
os.close(f)
os.chmod(path, 0o644)
os.rename(path, self.path)
def alert(self, msg=None):