resolved: make use of union in_addr_union in resolved, too
This commit is contained in:
parent
186fe1db20
commit
c92e531c82
|
@ -114,6 +114,8 @@ int manager_new(Manager **ret) {
|
|||
_cleanup_manager_free_ Manager *m = NULL;
|
||||
int r;
|
||||
|
||||
assert(ret);
|
||||
|
||||
m = new0(Manager, 1);
|
||||
if (!m)
|
||||
return -ENOMEM;
|
||||
|
|
|
@ -26,6 +26,7 @@
|
|||
|
||||
#include "util.h"
|
||||
#include "list.h"
|
||||
#include "socket-util.h"
|
||||
|
||||
typedef struct Address Address;
|
||||
typedef struct Manager Manager;
|
||||
|
@ -33,10 +34,7 @@ typedef struct Manager Manager;
|
|||
struct Address {
|
||||
unsigned char family;
|
||||
|
||||
union {
|
||||
struct in_addr in;
|
||||
struct in6_addr in6;
|
||||
} in_addr;
|
||||
union in_addr_union in_addr;
|
||||
|
||||
LIST_FIELDS(Address, addresses);
|
||||
};
|
||||
|
|
|
@ -1019,6 +1019,8 @@ static int manager_new(Manager **ret) {
|
|||
_cleanup_manager_free_ Manager *m = NULL;
|
||||
int r;
|
||||
|
||||
assert(ret);
|
||||
|
||||
m = new0(Manager, 1);
|
||||
if (!m)
|
||||
return -ENOMEM;
|
||||
|
|
Loading…
Reference in a new issue