aboutsummaryrefslogtreecommitdiffstats
path: root/openbsc/src/vty
diff options
context:
space:
mode:
Diffstat (limited to 'openbsc/src/vty')
-rw-r--r--openbsc/src/vty/command.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/openbsc/src/vty/command.c b/openbsc/src/vty/command.c
index c32e703f4..6372fb13b 100644
--- a/openbsc/src/vty/command.c
+++ b/openbsc/src/vty/command.c
@@ -2541,7 +2541,7 @@ DEFUN(config_write_file,
talloc_free(config_file_sav);
talloc_free(config_file_tmp);
- if (chmod(config_file, CONFIGFILE_MASK) != 0) {
+ if (chmod(config_file, 0666 & ~CONFIGFILE_MASK) != 0) {
vty_out(vty, "Can't chmod configuration file %s: %s (%d).%s",
config_file, strerror(errno), errno, VTY_NEWLINE);
return CMD_WARNING;