diff options
author | Donald Sharp <sharpd@cumulusnetworks.com> | 2018-04-09 15:41:08 +0200 |
---|---|---|
committer | Donald Sharp <sharpd@cumulusnetworks.com> | 2018-04-18 00:43:47 +0200 |
commit | 0f03639dedf5ef4242fb91b9b86903a3d179a17a (patch) | |
tree | 13cffb5c49cd9a196342b36ca61d82ba5fe4fce0 | |
parent | pbrd, zebra: Fix multiple pbr-policy install (diff) | |
download | frr-0f03639dedf5ef4242fb91b9b86903a3d179a17a.tar.xz frr-0f03639dedf5ef4242fb91b9b86903a3d179a17a.zip |
pbrd, zebra: Properly notice rule deletion
When a rule is deleted properly notice it in pbr.
Ticket: CM-20394
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
Diffstat (limited to '')
-rw-r--r-- | pbrd/pbr_zebra.c | 1 | ||||
-rw-r--r-- | zebra/zebra_pbr.c | 2 |
2 files changed, 3 insertions, 0 deletions
diff --git a/pbrd/pbr_zebra.c b/pbrd/pbr_zebra.c index cdb01bae9..931874748 100644 --- a/pbrd/pbr_zebra.c +++ b/pbrd/pbr_zebra.c @@ -237,6 +237,7 @@ static int rule_notify_owner(int command, struct zclient *zclient, __PRETTY_FUNCTION__); break; case ZAPI_RULE_REMOVED: + pbrms->installed &= ~installed; DEBUGD(&pbr_dbg_zebra, "%s: Received RULE REMOVED", __PRETTY_FUNCTION__); break; diff --git a/zebra/zebra_pbr.c b/zebra/zebra_pbr.c index 327b6a669..758365d71 100644 --- a/zebra/zebra_pbr.c +++ b/zebra/zebra_pbr.c @@ -496,8 +496,10 @@ void kernel_pbr_rule_add_del_status(struct zebra_pbr_rule *rule, zsend_rule_notify_owner(rule, ZAPI_RULE_FAIL_INSTALL); break; case SOUTHBOUND_DELETE_SUCCESS: + zsend_rule_notify_owner(rule, ZAPI_RULE_REMOVED); break; case SOUTHBOUND_DELETE_FAILURE: + zsend_rule_notify_owner(rule, ZAPI_RULE_REMOVED); break; } } |