Software /
code /
prosody
Changeset
6575:bdaadf70a48f
util.datamanager: Check that the global 'prosody' exists before using it (fixes nil indexing in use outside of prosody)
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Fri, 20 Feb 2015 19:00:01 +0100 |
parents | 6574:cd0088c73daf |
children | 6576:b7796a46aec2 6578:6f55db7afd3b |
files | util/datamanager.lua |
diffstat | 1 files changed, 1 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/util/datamanager.lua Fri Feb 20 15:51:05 2015 +0000 +++ b/util/datamanager.lua Fri Feb 20 19:00:01 2015 +0100 @@ -163,7 +163,7 @@ return nil, msg; end -if prosody.platform ~= "posix" then +if prosody and prosody.platform ~= "posix" then -- os.rename does not overwrite existing files on Windows -- TODO We could use Transactional NTFS on Vista and above function atomic_store(filename, data)