From: Steven Barth Date: Thu, 24 Jul 2014 19:18:00 +0000 (+0200) Subject: proto-shell: don't accept up-notifications in teardown state X-Git-Url: http://git.archive.openwrt.org/?p=project%2Fnetifd.git;a=commitdiff_plain;h=4156ba83483d0f1203fd17159974ae958325368c;hp=5844d3caa26f5f8810476836a8b711107e4ba8d7;ds=sidebyside proto-shell: don't accept up-notifications in teardown state Signed-off-by: Steven Barth --- diff --git a/proto-shell.c b/proto-shell.c index 7e9cbcf..d85a8d7 100644 --- a/proto-shell.c +++ b/proto-shell.c @@ -432,7 +432,7 @@ proto_shell_update_link(struct proto_shell_state *state, struct blob_attr *data, return UBUS_STATUS_INVALID_ARGUMENT; up = blobmsg_get_bool(tb[NOTIFY_LINK_UP]); - if (!up) { + if (!up || state->sm == S_TEARDOWN) { state->proto.proto_event(&state->proto, IFPEV_LINK_LOST); return 0; }