summaryrefslogtreecommitdiff
path: root/nest
diff options
context:
space:
mode:
Diffstat (limited to 'nest')
-rw-r--r--nest/iface.c9
-rw-r--r--nest/iface.h1
-rw-r--r--nest/proto.c8
3 files changed, 3 insertions, 15 deletions
diff --git a/nest/iface.c b/nest/iface.c
index fc896e26..fc63dc75 100644
--- a/nest/iface.c
+++ b/nest/iface.c
@@ -386,15 +386,6 @@ if_end_update(void)
}
}
-void
-if_flush_ifaces(struct proto *p)
-{
- if (p->debug & D_EVENTS)
- log(L_TRACE "%s: Flushing interfaces", p->name);
- if_start_update();
- if_end_update();
-}
-
/**
* if_feed_baby - advertise interfaces to a new protocol
* @p: protocol to feed
diff --git a/nest/iface.h b/nest/iface.h
index 13f3bd12..287f3d96 100644
--- a/nest/iface.h
+++ b/nest/iface.h
@@ -114,7 +114,6 @@ void ifa_delete(struct ifa *);
void if_start_update(void);
void if_end_partial_update(struct iface *);
void if_end_update(void);
-void if_flush_ifaces(struct proto *p);
void if_feed_baby(struct proto *);
struct iface *if_find_by_index(unsigned);
struct iface *if_find_by_name(const char *);
diff --git a/nest/proto.c b/nest/proto.c
index 26d648f3..0ca72ead 100644
--- a/nest/proto.c
+++ b/nest/proto.c
@@ -968,11 +968,8 @@ proto_event(void *ptr)
if (p->do_stop)
{
- if (p->proto == &proto_unix_iface)
- if_flush_ifaces(p);
p->do_stop = 0;
}
-
if (proto_is_done(p))
{
if (p->proto->cleanup)
@@ -1863,8 +1860,6 @@ proto_do_stop(struct proto *p)
p->down_sched = 0;
p->gr_recovery = 0;
- p->do_stop = 1;
- ev_schedule(p->event);
if (p->main_source)
{
@@ -1873,6 +1868,9 @@ proto_do_stop(struct proto *p)
}
proto_stop_channels(p);
+
+ p->do_stop = 1;
+ ev_schedule(p->event);
}
static void