aboutsummaryrefslogtreecommitdiffstats
path: root/src/lua/lua_util.c
diff options
context:
space:
mode:
authorVsevolod Stakhov <vsevolod@highsecure.ru>2017-05-09 13:59:56 +0100
committerVsevolod Stakhov <vsevolod@highsecure.ru>2017-05-09 14:06:40 +0100
commit4c2c4f0fdc54f9bdb5371a108c3dc7886e6c81ec (patch)
tree731e32b41934b03c0d7fc802f57e76eb58ea2cb1 /src/lua/lua_util.c
parent7b0d41173904268944de296ab85f20efef91bde5 (diff)
downloadrspamd-4c2c4f0fdc54f9bdb5371a108c3dc7886e6c81ec.tar.gz
rspamd-4c2c4f0fdc54f9bdb5371a108c3dc7886e6c81ec.zip
[Fix] Allow to follow symlinks when safe
Issue: #1625
Diffstat (limited to 'src/lua/lua_util.c')
-rw-r--r--src/lua/lua_util.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/lua/lua_util.c b/src/lua/lua_util.c
index 6c6a4201f..4c674def8 100644
--- a/src/lua/lua_util.c
+++ b/src/lua/lua_util.c
@@ -1632,7 +1632,7 @@ lua_util_create_file (lua_State *L)
mode = lua_tonumber (L, 2);
}
- fd = rspamd_file_xopen (fpath, O_RDWR|O_CREAT|O_EXCL, mode);
+ fd = rspamd_file_xopen (fpath, O_RDWR | O_CREAT | O_EXCL, mode, 0);
if (fd == -1) {
lua_pushnil (L);