diff --git a/nest/proto.c b/nest/proto.c index 3dcb3429..a6aa4e5c 100644 --- a/nest/proto.c +++ b/nest/proto.c @@ -602,7 +602,11 @@ proto_configure_channel(struct proto *p, struct channel **pc, struct channel_con if (!c && cf) { - *pc = proto_add_channel(p, cf); + /* We could add the channel, but currently it would just stay in down state + until protocol is restarted, so it is better to force restart anyways. */ + log(L_INFO "Cannot add channel %s.%s", p->name, cf->name); + return 0; + // *pc = proto_add_channel(p, cf); } else if (c && !cf) { diff --git a/proto/bgp/bgp.c b/proto/bgp/bgp.c index 496393ab..e20097ae 100644 --- a/proto/bgp/bgp.c +++ b/proto/bgp/bgp.c @@ -1878,7 +1878,9 @@ bgp_reconfigure(struct proto *P, struct proto_config *CF) { C = (struct channel *) bgp_find_channel(p, cc->afi); same = proto_configure_channel(P, &C, &cc->c) && same; - C->stale = 0; + + if (C) + C->stale = 0; } WALK_LIST_DELSAFE(C, C2, p->p.channels)