mirror of
https://github.com/systemd/systemd-stable.git
synced 2025-01-25 06:03:40 +03:00
sd-radv: use structured initializer at one more place
This commit is contained in:
parent
6ec11d46dc
commit
78f9d24f7b
@ -27,14 +27,14 @@ _public_ int sd_radv_new(sd_radv **ret) {
|
|||||||
|
|
||||||
assert_return(ret, -EINVAL);
|
assert_return(ret, -EINVAL);
|
||||||
|
|
||||||
ra = new0(sd_radv, 1);
|
ra = new(sd_radv, 1);
|
||||||
if (!ra)
|
if (!ra)
|
||||||
return -ENOMEM;
|
return -ENOMEM;
|
||||||
|
|
||||||
ra->n_ref = 1;
|
*ra = (sd_radv) {
|
||||||
ra->fd = -1;
|
.n_ref = 1,
|
||||||
|
.fd = -1,
|
||||||
LIST_HEAD_INIT(ra->prefixes);
|
};
|
||||||
|
|
||||||
*ret = TAKE_PTR(ra);
|
*ret = TAKE_PTR(ra);
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user