shared/socket-util: kill gcc warning about uninitialized variable
The warning was invalid, but distracting.
This commit is contained in:
parent
bf9d233f78
commit
6b6ed3e3eb
|
@ -363,13 +363,12 @@ int socket_address_print(const SocketAddress *a, char **p) {
|
||||||
}
|
}
|
||||||
|
|
||||||
case AF_NETLINK: {
|
case AF_NETLINK: {
|
||||||
char *sfamily;
|
char _cleanup_free_ *sfamily = NULL;
|
||||||
|
|
||||||
r = netlink_family_to_string_alloc(a->protocol, &sfamily);
|
r = netlink_family_to_string_alloc(a->protocol, &sfamily);
|
||||||
if (r < 0)
|
if (r < 0)
|
||||||
return r;
|
return r;
|
||||||
r = asprintf(p, "%s %u", sfamily, a->sockaddr.nl.nl_groups);
|
r = asprintf(p, "%s %u", sfamily, a->sockaddr.nl.nl_groups);
|
||||||
free(sfamily);
|
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue