config: Replace the config file with its new version, rather than copy2/remove.
This commit is contained in:
parent
1707b14691
commit
b3a944c76b
1 changed files with 1 additions and 2 deletions
|
@ -349,8 +349,7 @@ class Config(RawConfigParser):
|
|||
encoding='utf-8') as fd:
|
||||
for line in lines:
|
||||
fd.write('%s\n' % line)
|
||||
copy2(filename, self.file_name)
|
||||
remove(filename)
|
||||
filename.replace(self.file_name)
|
||||
except:
|
||||
success = False
|
||||
log.error('Unable to save the config file.', exc_info=True)
|
||||
|
|
Loading…
Reference in a new issue