mirror of
https://github.com/systemd/systemd.git
synced 2025-03-19 22:50:17 +03:00
core: fix owner user/group output in socket dump
The unit file settings are called SocketUser= and SocketGroup= hence name these fields that way in the "systemd-analyze dump" output too. https://github.com/systemd/systemd/issues/3171#issuecomment-216216995
This commit is contained in:
parent
1f15ce2846
commit
d2a50e3b52
@ -640,8 +640,8 @@ static void socket_dump(Unit *u, FILE *f, const char *prefix) {
|
||||
|
||||
if (!isempty(s->user) || !isempty(s->group))
|
||||
fprintf(f,
|
||||
"%sOwnerUser: %s\n"
|
||||
"%sOwnerGroup: %s\n",
|
||||
"%sSocketUser: %s\n"
|
||||
"%sSocketGroup: %s\n",
|
||||
prefix, strna(s->user),
|
||||
prefix, strna(s->group));
|
||||
|
||||
@ -1291,11 +1291,13 @@ static int socket_open_fds(Socket *s) {
|
||||
|
||||
/* Apply the socket protocol */
|
||||
switch(p->address.type) {
|
||||
|
||||
case SOCK_STREAM:
|
||||
case SOCK_SEQPACKET:
|
||||
if (p->socket->socket_protocol == IPPROTO_SCTP)
|
||||
p->address.protocol = p->socket->socket_protocol;
|
||||
break;
|
||||
|
||||
case SOCK_DGRAM:
|
||||
if (p->socket->socket_protocol == IPPROTO_UDPLITE)
|
||||
p->address.protocol = p->socket->socket_protocol;
|
||||
@ -1359,8 +1361,7 @@ static int socket_open_fds(Socket *s) {
|
||||
}
|
||||
break;
|
||||
|
||||
case SOCKET_USB_FUNCTION:
|
||||
{
|
||||
case SOCKET_USB_FUNCTION: {
|
||||
_cleanup_free_ char *ep = NULL;
|
||||
|
||||
ep = path_make_absolute("ep0", p->path);
|
||||
|
Loading…
x
Reference in New Issue
Block a user