Searched refs:un (Results 1 - 25 of 27) sorted by relevance

12

/systemd/src/reply-password/
H A Dreply-password.c24 #include <sys/un.h>
35 struct sockaddr_un un; member in union:__anon220
37 .un.sun_family = AF_UNIX,
44 strncpy(sa.un.sun_path, socket_name, sizeof(sa.un.sun_path));
/systemd/src/basic/
H A Ddef.h66 .un.sun_family = AF_UNIX, \
67 .un.sun_path = "\0/org/freedesktop/plymouthd", \
H A Dsocket-util.c94 if (l >= sizeof(a->sockaddr.un.sun_path))
97 a->sockaddr.un.sun_family = AF_UNIX;
98 memcpy(a->sockaddr.un.sun_path, s, l);
106 if (l >= sizeof(a->sockaddr.un.sun_path) - 1)
109 a->sockaddr.un.sun_family = AF_UNIX;
110 memcpy(a->sockaddr.un.sun_path+1, s+1, l);
261 if (a->sockaddr.un.sun_path[0] != 0) {
265 e = memchr(a->sockaddr.un.sun_path, 0, sizeof(a->sockaddr.un.sun_path));
269 if (a->size != offsetof(struct sockaddr_un, sun_path) + (e - a->sockaddr.un
[all...]
H A Dsocket-label.c27 #include <sys/un.h>
114 if (socket_address_family(a) == AF_UNIX && a->sockaddr.un.sun_path[0] != 0) {
118 mkdir_parents_label(a->sockaddr.un.sun_path, directory_mode);
127 unlink(a->sockaddr.un.sun_path);
H A Dselinux-util.c26 #include <sys/un.h>
423 const struct sockaddr_un *un; local
444 un = (const struct sockaddr_un*) addr;
445 if (un->sun_path[0] == 0)
448 path = strndupa(un->sun_path, addrlen - offsetof(struct sockaddr_un, sun_path));
H A Dsocket-util.h28 #include <sys/un.h>
39 struct sockaddr_un un; member in union:sockaddr_union
H A Dlog.c32 #include <sys/un.h>
153 .un.sun_family = AF_UNIX,
154 .un.sun_path = "/dev/log",
168 if (connect(syslog_fd, &sa.sa, offsetof(struct sockaddr_un, sun_path) + strlen(sa.un.sun_path)) < 0) {
180 if (connect(syslog_fd, &sa.sa, offsetof(struct sockaddr_un, sun_path) + strlen(sa.un.sun_path)) < 0) {
203 .un.sun_family = AF_UNIX,
204 .un.sun_path = "/run/systemd/journal/socket",
218 if (connect(journal_fd, &sa.sa, offsetof(struct sockaddr_un, sun_path) + strlen(sa.un.sun_path)) < 0) {
/systemd/src/socket-proxy/
H A Dsocket-proxyd.c28 #include <sys/un.h>
407 sa.un.sun_family = AF_UNIX;
408 strncpy(sa.un.sun_path, arg_remote_host, sizeof(sa.un.sun_path)-1);
409 sa.un.sun_path[sizeof(sa.un.sun_path)-1] = 0;
411 salen = offsetof(union sockaddr_union, un.sun_path) + strlen(sa.un.sun_path);
417 sa.un.sun_family = AF_UNIX;
418 sa.un
[all...]
/systemd/src/journal/
H A Djournald-syslog.c48 .un.sun_family = AF_UNIX,
49 .un.sun_path = "/run/systemd/journal/syslog",
55 .msg_namelen = offsetof(union sockaddr_union, un.sun_path)
393 .un.sun_family = AF_UNIX,
394 .un.sun_path = "/run/systemd/journal/dev-log",
401 unlink(sa.un.sun_path);
403 r = bind(s->syslog_fd, &sa.sa, offsetof(union sockaddr_union, un.sun_path) + strlen(sa.un.sun_path));
405 return log_error_errno(errno, "bind(%s) failed: %m", sa.un.sun_path);
407 (void) chmod(sa.un
[all...]
H A Djournald-native.c458 .un.sun_family = AF_UNIX,
459 .un.sun_path = "/run/systemd/journal/socket",
466 unlink(sa.un.sun_path);
468 r = bind(s->native_fd, &sa.sa, offsetof(union sockaddr_union, un.sun_path) + strlen(sa.un.sun_path));
470 return log_error_errno(errno, "bind(%s) failed: %m", sa.un.sun_path);
472 (void) chmod(sa.un.sun_path, 0666);
H A Djournald-stream.c709 .un.sun_family = AF_UNIX,
710 .un.sun_path = "/run/systemd/journal/stdout",
717 unlink(sa.un.sun_path);
719 r = bind(s->stdout_fd, &sa.sa, offsetof(union sockaddr_union, un.sun_path) + strlen(sa.un.sun_path));
721 return log_error_errno(errno, "bind(%s) failed: %m", sa.un.sun_path);
723 (void) chmod(sa.un.sun_path, 0666);
726 return log_error_errno(errno, "listen(%s) failed: %m", sa.un.sun_path);
H A Djournal-send.c25 #include <sys/un.h>
396 .un.sun_family = AF_UNIX,
397 .un.sun_path = "/run/systemd/journal/stdout",
411 r = connect(fd, &sa.sa, offsetof(union sockaddr_union, un.sun_path) + strlen(sa.un.sun_path));
H A Djournald-server.c1642 .un.sun_family = AF_UNIX,
1679 if (strlen(e) > sizeof(sa.un.sun_path)) {
1690 strncpy(sa.un.sun_path, e, sizeof(sa.un.sun_path));
1691 if (sa.un.sun_path[0] == '@')
1692 sa.un.sun_path[0] = 0;
/systemd/src/libsystemd/sd-daemon/
H A Dsd-daemon.c31 #include <sys/un.h>
357 memcmp(path, sockaddr.un.sun_path, length+1) == 0;
362 memcmp(path, sockaddr.un.sun_path, length) == 0;
442 if (strlen(e) > sizeof(sockaddr.un.sun_path)) {
457 strncpy(sockaddr.un.sun_path, e, sizeof(sockaddr.un.sun_path));
458 if (sockaddr.un.sun_path[0] == '@')
459 sockaddr.un.sun_path[0] = 0;
/systemd/src/udev/
H A Dudev-ctrl.c18 #include <sys/un.h>
106 uctrl->saddr.un.sun_family = AF_LOCAL;
107 strscpy(uctrl->saddr.un.sun_path, sizeof(uctrl->saddr.un.sun_path), "/run/udev/control");
108 uctrl->addrlen = offsetof(struct sockaddr_un, sun_path) + strlen(uctrl->saddr.un.sun_path);
122 unlink(uctrl->saddr.un.sun_path);
164 unlink(uctrl->saddr.un.sun_path);
/systemd/src/fsck/
H A Dfsck.c255 .un.sun_family = AF_UNIX,
256 .un.sun_path = "/run/systemd/fsck.progress",
265 if (connect(fd, &sa.sa, offsetof(struct sockaddr_un, sun_path) + strlen(sa.un.sun_path)) < 0) {
267 errno, "Failed to connect to progress socket %s, ignoring: %m", sa.un.sun_path);
/systemd/src/shared/
H A Dutmp-wtmp.c386 _cleanup_free_ char *text = NULL, *hn = NULL, *un = NULL, *stdin_tty = NULL; local
395 un = getlogname_malloc();
396 if (!un)
409 un ?: username, hn,
H A Dask-password-api.c38 #include <sys/un.h>
418 .un.sun_family = AF_UNIX,
431 snprintf(sa.un.sun_path, sizeof(sa.un.sun_path)-1, "/run/systemd/ask-password/sck.%" PRIx64, random_u64());
434 if (bind(fd, &sa.sa, offsetof(struct sockaddr_un, sun_path) + strlen(sa.un.sun_path)) < 0)
441 c = strdup(sa.un.sun_path);
/systemd/src/tty-ask-password-agent/
H A Dtty-ask-password-agent.c30 #include <sys/un.h>
97 r = connect(fd, &sa.sa, offsetof(struct sockaddr_un, sun_path) + 1 + strlen(sa.un.sun_path+1));
244 union sockaddr_union sa = { .un.sun_family = AF_UNIX };
270 strncpy(sa.un.sun_path, socket_name, sizeof(sa.un.sun_path));
/systemd/src/login/
H A Dpam_systemd.c128 .un.sun_family = AF_UNIX,
147 strncpy(sa.un.sun_path, p, sizeof(sa.un.sun_path)-1);
153 if (connect(fd, &sa.sa, offsetof(struct sockaddr_un, sun_path) + strlen(sa.un.sun_path)) < 0)
/systemd/src/core/
H A Ddbus.c971 .un.sun_family = AF_UNIX
992 strcpy(sa.un.sun_path, "/run/systemd/private");
993 salen = offsetof(union sockaddr_union, un.sun_path) + strlen("/run/systemd/private");
995 size_t left = sizeof(sa.un.sun_path);
996 char *p = sa.un.sun_path;
1008 salen = sizeof(sa.un) - left;
1011 (void) mkdir_parents_label(sa.un.sun_path, 0755);
1012 (void) unlink(sa.un.sun_path);
H A Dmanager.c716 strncpy(sa.un.sun_path, m->notify_socket, sizeof(sa.un.sun_path)-1);
717 r = bind(fd, &sa.sa, offsetof(struct sockaddr_un, sun_path) + strlen(sa.un.sun_path));
719 return log_error_errno(errno, "bind(%s) failed: %m", sa.un.sun_path);
2180 if (connect(fd, &sa.sa, offsetof(struct sockaddr_un, sun_path) + 1 + strlen(sa.un.sun_path+1)) < 0) {
/systemd/src/import/
H A Dimportd.c651 .un.sun_family = AF_UNIX,
652 .un.sun_path = "/run/systemd/import/notify",
677 (void) mkdir_parents_label(sa.un.sun_path, 0755);
678 (void) unlink(sa.un.sun_path);
680 if (bind(m->notify_fd, &sa.sa, offsetof(union sockaddr_union, un.sun_path) + strlen(sa.un.sun_path)) < 0)
/systemd/src/coredump/
H A Dcoredump.c836 .un.sun_family = AF_UNIX,
837 .un.sun_path = "/run/systemd/coredump",
850 if (connect(fd, &sa.sa, offsetof(union sockaddr_union, un.sun_path) + strlen(sa.un.sun_path)) < 0)
/systemd/src/libsystemd/sd-bus/
H A Dsd-bus.c576 if (l > sizeof(b->sockaddr.un.sun_path))
579 b->sockaddr.un.sun_family = AF_UNIX;
580 strncpy(b->sockaddr.un.sun_path, path, sizeof(b->sockaddr.un.sun_path));
584 if (l > sizeof(b->sockaddr.un.sun_path) - 1)
587 b->sockaddr.un.sun_family = AF_UNIX;
588 b->sockaddr.un.sun_path[0] = 0;
589 strncpy(b->sockaddr.un.sun_path+1, abstract, sizeof(b->sockaddr.un.sun_path)-1);
840 b->sockaddr.un
[all...]

Completed in 4820 milliseconds

12