fd 261 daemons/execd/remoted_tls.c int fd; fd 268 daemons/execd/remoted_tls.c fd = socket(addr->ai_family, addr->ai_socktype, addr->ai_protocol); fd 269 daemons/execd/remoted_tls.c if (fd < 0) { fd 276 daemons/execd/remoted_tls.c rc = setsockopt(fd, SOL_SOCKET, SO_REUSEADDR, &optval, sizeof(optval)); fd 279 daemons/execd/remoted_tls.c close(fd); fd 285 daemons/execd/remoted_tls.c rc = setsockopt(fd, IPPROTO_IPV6, IPV6_V6ONLY, &optval, sizeof(optval)); fd 288 daemons/execd/remoted_tls.c close(fd); fd 293 daemons/execd/remoted_tls.c if (bind(fd, addr->ai_addr, addr->ai_addrlen) != 0) { fd 295 daemons/execd/remoted_tls.c close(fd); fd 299 daemons/execd/remoted_tls.c if (listen(fd, 10) == -1) { fd 301 daemons/execd/remoted_tls.c close(fd); fd 304 daemons/execd/remoted_tls.c return fd; fd 143 daemons/fenced/cts-fence-helper.c rc = st->cmds->connect(st, crm_system_name, &pollfd.fd); fd 296 daemons/fenced/cts-fence-helper.c rc = st->cmds->connect(st, crm_system_name, &pollfd.fd); fd 322 daemons/fenced/cts-fence-helper.c rc = st->cmds->connect(st, crm_system_name, &pollfd.fd); fd 136 daemons/pacemakerd/pcmkd_corosync.c int fd = -1, retries = 0, rv; fd 155 daemons/pacemakerd/pcmkd_corosync.c rc = corosync_cfg_fd_get(cfg_handle, &fd); fd 163 daemons/pacemakerd/pcmkd_corosync.c if (!(rv = crm_ipc_is_authentic_process(fd, (uid_t) 0,(gid_t) 0, &found_pid, fd 194 daemons/pacemakerd/pcmkd_corosync.c mainloop_add_fd("corosync-cfg", G_PRIORITY_DEFAULT, fd, &cfg_handle, &cfg_fd_callbacks); fd 250 daemons/pacemakerd/pcmkd_corosync.c int fd = -1; fd 278 daemons/pacemakerd/pcmkd_corosync.c rc = cmap_fd_get(local_handle, &fd); fd 287 daemons/pacemakerd/pcmkd_corosync.c if (!(rv = crm_ipc_is_authentic_process(fd, (uid_t) 0,(gid_t) 0, &found_pid, fd 82 include/crm/common/internal.h int pcmk__write_sync(int fd, const char *contents); fd 83 include/crm/common/internal.h int pcmk__set_nonblocking(int fd); fd 147 include/crm/common/mainloop.h mainloop_io_t *mainloop_add_fd(const char *name, int priority, int fd, void *userdata, fd 128 include/crm/common/xml.h int write_xml_fd(xmlNode * xml_node, const char *filename, int fd, gboolean compress); fd 292 include/crm/lrmd.h int (*connect) (lrmd_t * lrmd, const char *client_name, int *fd); fd 105 include/portability.h int fd; /**< as Unix file descriptor */ fd 366 lib/cib/cib_file.c int rc, fd; fd 406 lib/cib/cib_file.c fd = mkstemp(tmp_cib); fd 407 lib/cib/cib_file.c if (fd < 0) { fd 415 lib/cib/cib_file.c if (fchmod(fd, S_IRUSR | S_IWUSR) < 0) { fd 421 lib/cib/cib_file.c if (cib_do_chown && (fchown(fd, cib_file_owner, cib_file_group) < 0)) { fd 429 lib/cib/cib_file.c if (write_xml_fd(cib_root, tmp_cib, fd, FALSE) <= 0) { fd 442 lib/cib/cib_file.c fd = mkstemp(tmp_digest); fd 443 lib/cib/cib_file.c if (fd < 0) { fd 448 lib/cib/cib_file.c if (cib_do_chown && (fchown(fd, cib_file_owner, cib_file_group) < 0)) { fd 452 lib/cib/cib_file.c close(fd); fd 455 lib/cib/cib_file.c rc = pcmk__write_sync(fd, digest); fd 460 lib/cib/cib_file.c close(fd); fd 463 lib/cib/cib_file.c close(fd); fd 110 lib/cluster/corosync.c int fd = -1; fd 144 lib/cluster/corosync.c rc = cmap_fd_get(cmap_handle, &fd); fd 152 lib/cluster/corosync.c if (!(rv = crm_ipc_is_authentic_process(fd, (uid_t) 0,(gid_t) 0, &found_pid, fd 350 lib/cluster/corosync.c int fd = 0; fd 375 lib/cluster/corosync.c rc = quorum_fd_get(pcmk_quorum_handle, &fd); fd 383 lib/cluster/corosync.c if (!(rv = crm_ipc_is_authentic_process(fd, (uid_t) 0,(gid_t) 0, &found_pid, fd 418 lib/cluster/corosync.c mainloop_add_fd("quorum", G_PRIORITY_HIGH, fd, dispatch, &quorum_fd_callbacks); fd 550 lib/cluster/corosync.c int fd = -1; fd 572 lib/cluster/corosync.c rc = cmap_fd_get(cmap_handle, &fd); fd 580 lib/cluster/corosync.c if (!(rv = crm_ipc_is_authentic_process(fd, (uid_t) 0,(gid_t) 0, &found_pid, fd 660 lib/cluster/corosync.c int fd = -1; fd 673 lib/cluster/corosync.c rc = cmap_fd_get(handle, &fd); fd 681 lib/cluster/corosync.c if (!(rv = crm_ipc_is_authentic_process(fd, (uid_t) 0,(gid_t) 0, &found_pid, fd 721 lib/cluster/corosync.c int fd = -1; fd 752 lib/cluster/corosync.c cs_rc = cmap_fd_get(cmap_handle, &fd); fd 761 lib/cluster/corosync.c rc = crm_ipc_is_authentic_process(fd, (uid_t) 0, (gid_t) 0, fd 124 lib/cluster/cpg.c int fd = -1; fd 143 lib/cluster/cpg.c rc = cpg_fd_get(local_handle, &fd); fd 151 lib/cluster/cpg.c if (!(rv = crm_ipc_is_authentic_process(fd, (uid_t) 0,(gid_t) 0, &found_pid, fd 774 lib/cluster/cpg.c int fd = -1; fd 813 lib/cluster/cpg.c rc = cpg_fd_get(handle, &fd); fd 821 lib/cluster/cpg.c if (!(rv = crm_ipc_is_authentic_process(fd, (uid_t) 0,(gid_t) 0, &found_pid, fd 853 lib/cluster/cpg.c mainloop_add_fd("corosync-cpg", G_PRIORITY_MEDIUM, fd, cluster, &cpg_fd_callbacks); fd 397 lib/common/io.c int fd; fd 406 lib/common/io.c fd = dirfd(directory); fd 407 lib/common/io.c if (fd < 0) { fd 412 lib/common/io.c if (fsync(fd) < 0) { fd 487 lib/common/io.c pcmk__write_sync(int fd, const char *contents) fd 490 lib/common/io.c FILE *fp = fdopen(fd, "w"); fd 517 lib/common/io.c pcmk__set_nonblocking(int fd) fd 519 lib/common/io.c int flag = fcntl(fd, F_GETFL); fd 524 lib/common/io.c if (fcntl(fd, F_SETFL, flag | O_NONBLOCK) < 0) { fd 369 lib/common/ipc_client.c pollfd.fd = crm_ipc_get_fd(api->ipc); fd 775 lib/common/ipc_client.c client->pfd.fd = -1; fd 808 lib/common/ipc_client.c client->pfd.fd = crm_ipc_get_fd(client); fd 809 lib/common/ipc_client.c if (client->pfd.fd < 0) { fd 825 lib/common/ipc_client.c if ((rv = pcmk__crm_ipc_is_authentic_process(client->ipc, client->pfd.fd, cl_uid, cl_gid, fd 903 lib/common/ipc_client.c int fd = 0; fd 905 lib/common/ipc_client.c if (client && client->ipc && (qb_ipcc_fd_get(client->ipc, &fd) == 0)) { fd 906 lib/common/ipc_client.c return fd; fd 927 lib/common/ipc_client.c } else if (client->pfd.fd < 0) { fd 934 lib/common/ipc_client.c client->pfd.fd = -EINVAL; fd 1403 lib/common/ipc_client.c int fd; fd 1417 lib/common/ipc_client.c qb_rc = qb_ipcc_fd_get(c, &fd); fd 1425 lib/common/ipc_client.c auth_rc = pcmk__crm_ipc_is_authentic_process(c, fd, refuid, refgid, &found_pid, fd 267 lib/common/logging.c enable_logfile(int fd) fd 269 lib/common/logging.c qb_log_ctl(fd, QB_LOG_CONF_ENABLED, QB_TRUE); fd 271 lib/common/logging.c qb_log_ctl(fd, QB_LOG_CONF_FILE_SYNC, 1); // Turn on synchronous writes fd 276 lib/common/logging.c qb_log_ctl(fd, QB_LOG_CONF_MAX_LINE_LEN, 800); fd 283 lib/common/logging.c disable_logfile(int fd) fd 285 lib/common/logging.c qb_log_ctl(fd, QB_LOG_CONF_ENABLED, QB_FALSE); fd 312 lib/common/logging.c int fd = 0; fd 355 lib/common/logging.c fd = qb_log_file_open(filename); fd 356 lib/common/logging.c if (fd < 0) { fd 358 lib/common/logging.c filename, strerror(-fd)); fd 359 lib/common/logging.c return -fd; // == +errno fd 363 lib/common/logging.c default_fd = fd; fd 372 lib/common/logging.c enable_logfile(fd); fd 456 lib/common/mainloop.c gint fd = g_io_channel_unix_get_fd(gio); fd 458 lib/common/mainloop.c crm_trace("%p.%d %d", data, fd, condition); fd 464 lib/common/mainloop.c return (adaptor->fn(fd, condition, adaptor->data) == 0); fd 541 lib/common/mainloop.c gio_poll_dispatch_update(enum qb_loop_priority p, int32_t fd, int32_t evts, fd 548 lib/common/mainloop.c res = qb_array_index(gio_map, fd, (void **)&adaptor); fd 550 lib/common/mainloop.c crm_err("Array lookup failed for fd=%d: %d", fd, res); fd 554 lib/common/mainloop.c crm_trace("Adding fd=%d to mainloop as adaptor %p", fd, adaptor); fd 557 lib/common/mainloop.c crm_err("Adaptor for descriptor %d is still in-use", fd); fd 561 lib/common/mainloop.c crm_err("Adaptor for descriptor %d is not in-use", fd); fd 566 lib/common/mainloop.c channel = g_io_channel_unix_new(fd); fd 568 lib/common/mainloop.c crm_err("No memory left to add fd=%d", fd); fd 609 lib/common/mainloop.c gio_poll_dispatch_add(enum qb_loop_priority p, int32_t fd, int32_t evts, fd 612 lib/common/mainloop.c return gio_poll_dispatch_update(p, fd, evts, data, fn, QB_TRUE); fd 616 lib/common/mainloop.c gio_poll_dispatch_mod(enum qb_loop_priority p, int32_t fd, int32_t evts, fd 619 lib/common/mainloop.c return gio_poll_dispatch_update(p, fd, evts, data, fn, QB_FALSE); fd 623 lib/common/mainloop.c gio_poll_dispatch_del(int32_t fd) fd 627 lib/common/mainloop.c crm_trace("Looking for fd=%d", fd); fd 628 lib/common/mainloop.c if (qb_array_index(gio_map, fd, (void **)&adaptor) == 0) { fd 724 lib/common/mainloop.c int fd; fd 751 lib/common/mainloop.c CRM_ASSERT(client->fd == g_io_channel_unix_get_fd(gio)); fd 975 lib/common/mainloop.c mainloop_add_fd(const char *name, int priority, int fd, void *userdata, fd 980 lib/common/mainloop.c if (fd >= 0) { fd 993 lib/common/mainloop.c client->fd = fd; fd 994 lib/common/mainloop.c client->channel = g_io_channel_unix_new(fd); fd 1010 lib/common/mainloop.c crm_trace("Added connection %d for %s[%p].%d", client->source, client->name, client, fd); fd 125 lib/common/pid.c int fd; fd 133 lib/common/pid.c fd = open(filename, O_RDONLY); fd 134 lib/common/pid.c if (fd < 0) { fd 138 lib/common/pid.c if ((fstat(fd, &sbuf) >= 0) && (sbuf.st_size < LOCKSTRLEN)) { fd 144 lib/common/pid.c if (read(fd, buf, sizeof(buf)) < 1) { fd 160 lib/common/pid.c close(fd); fd 222 lib/common/pid.c int fd = 0; fd 232 lib/common/pid.c fd = open(filename, O_CREAT | O_WRONLY | O_EXCL, 0644); fd 233 lib/common/pid.c if (fd < 0) { fd 238 lib/common/pid.c rc = write(fd, buf, LOCKSTRLEN); fd 239 lib/common/pid.c close(fd); fd 42 lib/common/procfs.c int fd, local_pid; fd 63 lib/common/procfs.c fd = open(procpath, O_RDONLY); fd 64 lib/common/procfs.c if (fd < 0 ) { fd 67 lib/common/procfs.c if (fstat(fd, &statbuf) < 0) { fd 68 lib/common/procfs.c close(fd); fd 71 lib/common/procfs.c close(fd); fd 650 lib/common/remote.c fds.fd = sock; fd 674 lib/common/schemas.c int fd = 0; fd 683 lib/common/schemas.c fd = mkstemp(filename); fd 684 lib/common/schemas.c write_xml_fd(xml_blob, filename, fd, FALSE); fd 1270 lib/common/xml.c write_xml_fd(xmlNode * xml_node, const char *filename, int fd, gboolean compress) fd 1276 lib/common/xml.c CRM_CHECK(xml_node && (fd > 0), return -EINVAL); fd 1277 lib/common/xml.c stream = fdopen(fd, "w"); fd 1009 lib/lrmd/lrmd_client.c lrmd_ipc_connect(lrmd_t * lrmd, int *fd) fd 1021 lib/lrmd/lrmd_client.c if (fd) { fd 1025 lib/lrmd/lrmd_client.c *fd = crm_ipc_get_fd(native->ipc); fd 1456 lib/lrmd/lrmd_client.c lrmd_tls_connect(lrmd_t * lrmd, int *fd) fd 1506 lib/lrmd/lrmd_client.c if (fd) { fd 1507 lib/lrmd/lrmd_client.c *fd = native->sock; fd 1516 lib/lrmd/lrmd_client.c lrmd_api_connect(lrmd_t * lrmd, const char *name, int *fd) fd 1523 lib/lrmd/lrmd_client.c rc = lrmd_ipc_connect(lrmd, fd); fd 1527 lib/lrmd/lrmd_client.c rc = lrmd_tls_connect(lrmd, fd); fd 156 lib/services/dbus.c int fd = dbus_watch_get_unix_fd(watch); fd 158 lib/services/dbus.c mainloop_io_t *client = mainloop_add_fd("dbus", G_PRIORITY_DEFAULT, fd, fd 161 lib/services/dbus.c crm_trace("Added DBus watch for file descriptor %d", fd); fd 77 lib/services/services_linux.c int fd; fd 81 lib/services/services_linux.c fd = signalfd(-1, &(data->mask), SFD_NONBLOCK); fd 82 lib/services/services_linux.c if (fd < 0) { fd 86 lib/services/services_linux.c return fd; fd 91 lib/services/services_linux.c sigchld_close(int fd) fd 93 lib/services/services_linux.c if (fd > 0) { fd 94 lib/services/services_linux.c close(fd); fd 100 lib/services/services_linux.c sigchld_received(int fd) fd 105 lib/services/services_linux.c if (fd < 0) { fd 108 lib/services/services_linux.c s = read(fd, &fdsi, sizeof(struct signalfd_siginfo)); fd 202 lib/services/services_linux.c sigchld_close(int fd) fd 209 lib/services/services_linux.c sigchld_received(int fd) fd 213 lib/services/services_linux.c if (fd < 0) { fd 218 lib/services/services_linux.c while (read(fd, &ch, 1) == 1) /*omit*/; fd 256 lib/services/services_linux.c svc_read_output(int fd, svc_action_t * op, bool is_stderr) fd 264 lib/services/services_linux.c if (fd < 0) { fd 284 lib/services/services_linux.c rc = read(fd, buf, buf_read_len); fd 543 lib/services/services_linux.c int fd; fd 547 lib/services/services_linux.c fd = op->opaque->stderr_fd; fd 550 lib/services/services_linux.c fd = op->opaque->stdout_fd; fd 556 lib/services/services_linux.c svc_read_output(fd, op, is_stderr); fd 558 lib/services/services_linux.c close(fd); fd 772 lib/services/services_linux.c fds[0].fd = op->opaque->stdout_fd; fd 776 lib/services/services_linux.c fds[1].fd = op->opaque->stderr_fd; fd 780 lib/services/services_linux.c fds[2].fd = sigchld_open(data); fd 798 lib/services/services_linux.c if ((fds[2].revents & POLLIN) && sigchld_received(fds[2].fd)) { fd 874 lib/services/services_linux.c sigchld_close(fds[2].fd);