mirror of
https://github.com/fluencelabs/redis
synced 2025-03-17 16:10:50 +00:00
Unlink Unix socket file on shutdown
This commit is contained in:
parent
ff15dba093
commit
56209f720a
@ -1236,6 +1236,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;
|
||||
|
Loading…
x
Reference in New Issue
Block a user