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
1ca8deeb
Commit
1ca8deeb
authored
Oct 09, 2011
by
Nathan Florea
Committed by
antirez
Oct 10, 2011
Browse files
Unlink Unix socket file on shutdown
parent
b7f667b5
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/redis.c
View file @
1ca8deeb
...
...
@@ -1170,6 +1170,10 @@ int prepareForShutdown() {
/* Close the listening sockets. Apparently this allows faster restarts. */
if
(
server
.
ipfd
!=
-
1
)
close
(
server
.
ipfd
);
if
(
server
.
sofd
!=
-
1
)
close
(
server
.
sofd
);
if
(
server
.
unixsocket
)
{
redisLog
(
REDIS_NOTICE
,
"Removing the unix socket file."
);
unlink
(
server
.
unixsocket
);
/* don't care if this fails */
}
redisLog
(
REDIS_WARNING
,
"Redis is now ready to exit, bye bye..."
);
return
REDIS_OK
;
...
...
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