diff options
Diffstat (limited to 'proto/pipe/pipe.c')
-rw-r--r-- | proto/pipe/pipe.c | 11 |
1 files changed, 3 insertions, 8 deletions
diff --git a/proto/pipe/pipe.c b/proto/pipe/pipe.c index e122d771..99d4b737 100644 --- a/proto/pipe/pipe.c +++ b/proto/pipe/pipe.c @@ -58,19 +58,14 @@ pipe_rt_notify(struct proto *P, struct channel *src_ch, const net_addr *n, rte * if (new) { - rta *a = alloca(rta_size(new->attrs)); - memcpy(a, new->attrs, rta_size(new->attrs)); - - a->cached = 0; - ea_unset_attr(&a->eattrs, 0, &ea_gen_hostentry); - - rte e0 = { - .attrs = a, + .attrs = new->attrs, .src = new->src, .generation = new->generation + 1, }; + ea_unset_attr(&e0.attrs, 0, &ea_gen_hostentry); + rte_update(dst, n, &e0, new->src); } else |