fd 263 daemons/execd/remoted_tls.c int fd; fd 270 daemons/execd/remoted_tls.c fd = socket(addr->ai_family, addr->ai_socktype, addr->ai_protocol); fd 271 daemons/execd/remoted_tls.c if (fd < 0) { fd 278 daemons/execd/remoted_tls.c rc = setsockopt(fd, SOL_SOCKET, SO_REUSEADDR, &optval, sizeof(optval)); fd 281 daemons/execd/remoted_tls.c close(fd); fd 287 daemons/execd/remoted_tls.c rc = setsockopt(fd, IPPROTO_IPV6, IPV6_V6ONLY, &optval, sizeof(optval)); fd 290 daemons/execd/remoted_tls.c close(fd); fd 295 daemons/execd/remoted_tls.c if (bind(fd, addr->ai_addr, addr->ai_addrlen) != 0) { fd 297 daemons/execd/remoted_tls.c close(fd); fd 301 daemons/execd/remoted_tls.c if (listen(fd, 10) == -1) { fd 303 daemons/execd/remoted_tls.c close(fd); fd 306 daemons/execd/remoted_tls.c return fd; fd 142 daemons/fenced/cts-fence-helper.c rc = st->cmds->connect(st, crm_system_name, &pollfd.fd); fd 291 daemons/fenced/cts-fence-helper.c rc = st->cmds->connect(st, crm_system_name, &pollfd.fd); fd 317 daemons/fenced/cts-fence-helper.c rc = st->cmds->connect(st, crm_system_name, &pollfd.fd); fd 98 daemons/pacemakerd/pcmkd_corosync.c int fd = -1, retries = 0, rv; fd 117 daemons/pacemakerd/pcmkd_corosync.c rc = corosync_cfg_fd_get(cfg_handle, &fd); fd 125 daemons/pacemakerd/pcmkd_corosync.c if (!(rv = crm_ipc_is_authentic_process(fd, (uid_t) 0,(gid_t) 0, &found_pid, fd 147 daemons/pacemakerd/pcmkd_corosync.c mainloop_add_fd("corosync-cfg", G_PRIORITY_DEFAULT, fd, &cfg_handle, &cfg_fd_callbacks); fd 204 daemons/pacemakerd/pcmkd_corosync.c int fd = -1; fd 232 daemons/pacemakerd/pcmkd_corosync.c rc = cmap_fd_get(local_handle, &fd); fd 241 daemons/pacemakerd/pcmkd_corosync.c if (!(rv = crm_ipc_is_authentic_process(fd, (uid_t) 0,(gid_t) 0, &found_pid, fd 74 include/crm/common/internal.h int pcmk__write_sync(int fd, const char *contents); fd 75 include/crm/common/internal.h int pcmk__set_nonblocking(int fd); fd 119 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 293 include/crm/lrmd.h int (*connect) (lrmd_t * lrmd, const char *client_name, int *fd); fd 128 include/portability.h int fd; /**< as Unix file descriptor */ fd 364 lib/cib/cib_file.c int rc, fd; fd 404 lib/cib/cib_file.c fd = mkstemp(tmp_cib); fd 405 lib/cib/cib_file.c if (fd < 0) { fd 413 lib/cib/cib_file.c if (fchmod(fd, S_IRUSR | S_IWUSR) < 0) { fd 419 lib/cib/cib_file.c if (cib_do_chown && (fchown(fd, cib_file_owner, cib_file_group) < 0)) { fd 427 lib/cib/cib_file.c if (write_xml_fd(cib_root, tmp_cib, fd, FALSE) <= 0) { fd 440 lib/cib/cib_file.c fd = mkstemp(tmp_digest); fd 441 lib/cib/cib_file.c if (fd < 0) { fd 446 lib/cib/cib_file.c if (cib_do_chown && (fchown(fd, cib_file_owner, cib_file_group) < 0)) { fd 450 lib/cib/cib_file.c close(fd); fd 453 lib/cib/cib_file.c rc = pcmk__write_sync(fd, digest); fd 458 lib/cib/cib_file.c close(fd); fd 461 lib/cib/cib_file.c close(fd); fd 68 lib/cluster/corosync.c int fd = -1; fd 102 lib/cluster/corosync.c rc = cmap_fd_get(cmap_handle, &fd); fd 110 lib/cluster/corosync.c if (!(rv = crm_ipc_is_authentic_process(fd, (uid_t) 0,(gid_t) 0, &found_pid, fd 276 lib/cluster/corosync.c int fd = 0; fd 301 lib/cluster/corosync.c rc = quorum_fd_get(pcmk_quorum_handle, &fd); fd 309 lib/cluster/corosync.c if (!(rv = crm_ipc_is_authentic_process(fd, (uid_t) 0,(gid_t) 0, &found_pid, fd 344 lib/cluster/corosync.c mainloop_add_fd("quorum", G_PRIORITY_HIGH, fd, dispatch, &quorum_fd_callbacks); fd 537 lib/cluster/corosync.c int fd = -1; fd 559 lib/cluster/corosync.c rc = cmap_fd_get(cmap_handle, &fd); fd 567 lib/cluster/corosync.c if (!(rv = crm_ipc_is_authentic_process(fd, (uid_t) 0,(gid_t) 0, &found_pid, fd 644 lib/cluster/corosync.c int fd = -1; fd 657 lib/cluster/corosync.c rc = cmap_fd_get(handle, &fd); fd 665 lib/cluster/corosync.c if (!(rv = crm_ipc_is_authentic_process(fd, (uid_t) 0,(gid_t) 0, &found_pid, fd 712 lib/cluster/corosync.c int fd = -1; fd 739 lib/cluster/corosync.c rc = cmap_fd_get(cmap_handle, &fd); fd 747 lib/cluster/corosync.c if (!(rv = crm_ipc_is_authentic_process(fd, (uid_t) 0,(gid_t) 0, &found_pid, fd 72 lib/cluster/cpg.c int fd = -1; fd 91 lib/cluster/cpg.c rc = cpg_fd_get(local_handle, &fd); fd 99 lib/cluster/cpg.c if (!(rv = crm_ipc_is_authentic_process(fd, (uid_t) 0,(gid_t) 0, &found_pid, fd 542 lib/cluster/cpg.c int fd = -1; fd 581 lib/cluster/cpg.c rc = cpg_fd_get(handle, &fd); fd 589 lib/cluster/cpg.c if (!(rv = crm_ipc_is_authentic_process(fd, (uid_t) 0,(gid_t) 0, &found_pid, fd 621 lib/cluster/cpg.c mainloop_add_fd("corosync-cpg", G_PRIORITY_MEDIUM, fd, cluster, &cpg_fd_callbacks); fd 416 lib/common/io.c int fd; fd 425 lib/common/io.c fd = dirfd(directory); fd 426 lib/common/io.c if (fd < 0) { fd 431 lib/common/io.c if (fsync(fd) < 0) { fd 506 lib/common/io.c pcmk__write_sync(int fd, const char *contents) fd 509 lib/common/io.c FILE *fp = fdopen(fd, "w"); fd 536 lib/common/io.c pcmk__set_nonblocking(int fd) fd 538 lib/common/io.c int flag = fcntl(fd, F_GETFL); fd 543 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 773 lib/common/ipc_client.c client->pfd.fd = -1; fd 805 lib/common/ipc_client.c client->pfd.fd = crm_ipc_get_fd(client); fd 806 lib/common/ipc_client.c if (client->pfd.fd < 0) { fd 822 lib/common/ipc_client.c if (!(rv = crm_ipc_is_authentic_process(client->pfd.fd, cl_uid, cl_gid, fd 895 lib/common/ipc_client.c int fd = 0; fd 897 lib/common/ipc_client.c if (client && client->ipc && (qb_ipcc_fd_get(client->ipc, &fd) == 0)) { fd 898 lib/common/ipc_client.c return fd; fd 919 lib/common/ipc_client.c } else if (client->pfd.fd < 0) { fd 926 lib/common/ipc_client.c client->pfd.fd = -EINVAL; fd 1360 lib/common/ipc_client.c int fd; fd 1374 lib/common/ipc_client.c qb_rc = qb_ipcc_fd_get(c, &fd); fd 1382 lib/common/ipc_client.c auth_rc = crm_ipc_is_authentic_process(fd, refuid, refgid, &found_pid, fd 179 lib/common/logging.c int fd = 0, rc = 0; fd 280 lib/common/logging.c fd = qb_log_file_open(filename); fd 282 lib/common/logging.c if (fd < 0) { fd 288 lib/common/logging.c default_fd = fd; fd 301 lib/common/logging.c qb_log_ctl(fd, QB_LOG_CONF_ENABLED, QB_TRUE); fd 306 lib/common/logging.c qb_log_ctl(fd, QB_LOG_CONF_MAX_LINE_LEN, 800); fd 429 lib/common/mainloop.c gint fd = g_io_channel_unix_get_fd(gio); fd 431 lib/common/mainloop.c crm_trace("%p.%d %d", data, fd, condition); fd 437 lib/common/mainloop.c return (adaptor->fn(fd, condition, adaptor->data) == 0); fd 514 lib/common/mainloop.c gio_poll_dispatch_update(enum qb_loop_priority p, int32_t fd, int32_t evts, fd 521 lib/common/mainloop.c res = qb_array_index(gio_map, fd, (void **)&adaptor); fd 523 lib/common/mainloop.c crm_err("Array lookup failed for fd=%d: %d", fd, res); fd 527 lib/common/mainloop.c crm_trace("Adding fd=%d to mainloop as adaptor %p", fd, adaptor); fd 530 lib/common/mainloop.c crm_err("Adaptor for descriptor %d is still in-use", fd); fd 534 lib/common/mainloop.c crm_err("Adaptor for descriptor %d is not in-use", fd); fd 539 lib/common/mainloop.c channel = g_io_channel_unix_new(fd); fd 541 lib/common/mainloop.c crm_err("No memory left to add fd=%d", fd); fd 582 lib/common/mainloop.c gio_poll_dispatch_add(enum qb_loop_priority p, int32_t fd, int32_t evts, fd 585 lib/common/mainloop.c return gio_poll_dispatch_update(p, fd, evts, data, fn, QB_TRUE); fd 589 lib/common/mainloop.c gio_poll_dispatch_mod(enum qb_loop_priority p, int32_t fd, int32_t evts, fd 592 lib/common/mainloop.c return gio_poll_dispatch_update(p, fd, evts, data, fn, QB_FALSE); fd 596 lib/common/mainloop.c gio_poll_dispatch_del(int32_t fd) fd 600 lib/common/mainloop.c crm_trace("Looking for fd=%d", fd); fd 601 lib/common/mainloop.c if (qb_array_index(gio_map, fd, (void **)&adaptor) == 0) { fd 700 lib/common/mainloop.c int fd; fd 717 lib/common/mainloop.c CRM_ASSERT(client->fd == g_io_channel_unix_get_fd(gio)); fd 915 lib/common/mainloop.c mainloop_add_fd(const char *name, int priority, int fd, void *userdata, fd 920 lib/common/mainloop.c if (fd >= 0) { fd 933 lib/common/mainloop.c client->fd = fd; fd 934 lib/common/mainloop.c client->channel = g_io_channel_unix_new(fd); fd 950 lib/common/mainloop.c crm_trace("Added connection %d for %s[%p].%d", client->source, client->name, client, fd); fd 120 lib/common/pid.c int fd; fd 128 lib/common/pid.c fd = open(filename, O_RDONLY); fd 129 lib/common/pid.c if (fd < 0) { fd 133 lib/common/pid.c if ((fstat(fd, &sbuf) >= 0) && (sbuf.st_size < LOCKSTRLEN)) { fd 139 lib/common/pid.c if (read(fd, buf, sizeof(buf)) < 1) { fd 155 lib/common/pid.c close(fd); fd 217 lib/common/pid.c int fd = 0; fd 227 lib/common/pid.c fd = open(filename, O_CREAT | O_WRONLY | O_EXCL, 0644); fd 228 lib/common/pid.c if (fd < 0) { fd 233 lib/common/pid.c rc = write(fd, buf, LOCKSTRLEN); fd 234 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 663 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 1249 lib/common/xml.c write_xml_fd(xmlNode * xml_node, const char *filename, int fd, gboolean compress) fd 1255 lib/common/xml.c CRM_CHECK(xml_node && (fd > 0), return -EINVAL); fd 1256 lib/common/xml.c stream = fdopen(fd, "w"); fd 1008 lib/lrmd/lrmd_client.c lrmd_ipc_connect(lrmd_t * lrmd, int *fd) fd 1020 lib/lrmd/lrmd_client.c if (fd) { fd 1024 lib/lrmd/lrmd_client.c *fd = crm_ipc_get_fd(native->ipc); fd 1281 lib/lrmd/lrmd_client.c lrmd_tls_connect(lrmd_t * lrmd, int *fd) fd 1335 lib/lrmd/lrmd_client.c if (fd) { fd 1336 lib/lrmd/lrmd_client.c *fd = native->sock; fd 1351 lib/lrmd/lrmd_client.c lrmd_api_connect(lrmd_t * lrmd, const char *name, int *fd) fd 1358 lib/lrmd/lrmd_client.c rc = lrmd_ipc_connect(lrmd, fd); fd 1362 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);