vRouter: ignore routes that don't come from Quagga
Change-Id: I1a67a18b7f5f0a4e43156c017b92c12789e81104
diff --git a/apps/routing/src/main/java/org/onosproject/routing/fpm/FpmManager.java b/apps/routing/src/main/java/org/onosproject/routing/fpm/FpmManager.java
index d89ae4e..efda592 100644
--- a/apps/routing/src/main/java/org/onosproject/routing/fpm/FpmManager.java
+++ b/apps/routing/src/main/java/org/onosproject/routing/fpm/FpmManager.java
@@ -41,6 +41,7 @@
import org.onosproject.routing.fpm.protocol.RouteAttributeDst;
import org.onosproject.routing.fpm.protocol.RouteAttributeGateway;
import org.onosproject.routing.fpm.protocol.RtNetlink;
+import org.onosproject.routing.fpm.protocol.RtProtocol;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
@@ -145,6 +146,11 @@
log.trace("Received FPM message: {}", fpmMessage);
}
+ if (rtNetlink.protocol() != RtProtocol.ZEBRA) {
+ log.trace("Ignoring non-zebra route");
+ return;
+ }
+
IpAddress dstAddress = null;
IpAddress gateway = null;