Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
ruanhaishen
redis
Commits
9e74d216
Commit
9e74d216
authored
May 14, 2013
by
antirez
Browse files
CONFIG REWRITE: Use sane perms when creating redis.conf from scratch.
parent
e2520454
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/config.c
View file @
9e74d216
...
@@ -1481,7 +1481,7 @@ void rewriteConfigRemoveOrphaned(struct rewriteConfigState *state) {
...
@@ -1481,7 +1481,7 @@ void rewriteConfigRemoveOrphaned(struct rewriteConfigState *state) {
* set accordingly. */
* set accordingly. */
int rewriteConfigOverwriteFile(char *configfile, sds content) {
int rewriteConfigOverwriteFile(char *configfile, sds content) {
int retval = 0;
int retval = 0;
int fd = open(configfile,O_RDWR|O_CREAT);
int fd = open(configfile,O_RDWR|O_CREAT
,0644
);
int content_size = sdslen(content), padding = 0;
int content_size = sdslen(content), padding = 0;
struct stat sb;
struct stat sb;
sds content_padded;
sds content_padded;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment