diff mbox

[net,v3,2/2] mpls: fix mpls route deletes to not check for route scope

Message ID 1433226567-23302-3-git-send-email-roopa@cumulusnetworks.com
State Changes Requested, archived
Delegated to: David Miller
Headers show

Commit Message

Roopa Prabhu June 2, 2015, 6:29 a.m. UTC
From: Roopa Prabhu <roopa@cumulusnetworks.com>

Ignore scope for route del messages

Signed-off-by: Vivek Venkataraman <vivek@cumulusnetworks.com>
Signed-off-by: Roopa Prabhu <roopa@cumulusnetworks.com>
Reviewed-by: Robert Shearman <rshearma@brocade.com> 
---
 net/mpls/af_mpls.c |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
diff mbox

Patch

diff --git a/net/mpls/af_mpls.c b/net/mpls/af_mpls.c
index 7b3f732..82dadab 100644
--- a/net/mpls/af_mpls.c
+++ b/net/mpls/af_mpls.c
@@ -693,7 +693,8 @@  static int rtm_to_route_config(struct sk_buff *skb,  struct nlmsghdr *nlh,
 	 * (or source specific address in the case of multicast)
 	 * all addresses have universal scope.
 	 */
-	if (rtm->rtm_scope != RT_SCOPE_UNIVERSE)
+	if (nlh->nlmsg_type != RTM_DELROUTE &&
+	    rtm->rtm_scope != RT_SCOPE_UNIVERSE)
 		goto errout;
 	if (rtm->rtm_type != RTN_UNICAST)
 		goto errout;