]> git.proxmox.com Git - ceph.git/blobdiff - ceph/src/common/HeartbeatMap.cc
update sources to 12.2.10
[ceph.git] / ceph / src / common / HeartbeatMap.cc
index ae1f8e8faae78a66eda32f5cb083ddd730ff1d85..f6822852da4fc495d1260dc4b0981c894c128d11 100644 (file)
@@ -165,7 +165,7 @@ void HeartbeatMap::check_touch_file()
   if (is_healthy()) {
     string path = m_cct->_conf->heartbeat_file;
     if (path.length()) {
-      int fd = ::open(path.c_str(), O_WRONLY|O_CREAT, 0644);
+      int fd = ::open(path.c_str(), O_WRONLY|O_CREAT|O_CLOEXEC, 0644);
       if (fd >= 0) {
        ::utimes(path.c_str(), NULL);
        ::close(fd);