提交 03ca9039 编写于 作者: A antirez

Cluster: fsync data when saving the cluster config.

上级 026e6339
......@@ -231,6 +231,7 @@ int clusterSaveConfig(void) {
if ((fd = open(server.cluster_configfile,O_WRONLY|O_CREAT|O_TRUNC,0644))
== -1) goto err;
if (write(fd,ci,sdslen(ci)) != (ssize_t)sdslen(ci)) goto err;
fsync(fd);
close(fd);
sdsfree(ci);
return 0;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册