Revert "Notify network observers of route changes."
This reverts commit d2f23fb6285000831f14cacc16881d96f6046c33.
Change-Id: Ifabbc6848ab33842461465fccb9886863a08aec6
diff --git a/server/NetlinkHandler.cpp b/server/NetlinkHandler.cpp
index d1dbf7d..4f421c5 100644
--- a/server/NetlinkHandler.cpp
+++ b/server/NetlinkHandler.cpp
@@ -29,9 +29,6 @@
#include "NetlinkManager.h"
#include "ResponseCode.h"
-static const char *kUpdated = "updated";
-static const char *kRemoved = "removed";
-
NetlinkHandler::NetlinkHandler(NetlinkManager *nm, int listenerSocket,
int format) :
NetlinkListener(listenerSocket, format) {
@@ -85,14 +82,6 @@
if (lifetime && servers) {
notifyInterfaceDnsServers(iface, lifetime, servers);
}
- } else if (action == evt->NlActionRouteUpdated ||
- action == evt->NlActionRouteRemoved) {
- const char *route = evt->findParam("ROUTE");
- const char *gateway = evt->findParam("GATEWAY");
- const char *iface = evt->findParam("INTERFACE");
- if (route && (gateway || iface)) {
- notifyRouteChange(action, route, gateway, iface);
- }
}
} else if (!strcmp(subsys, "qlog")) {
@@ -165,8 +154,8 @@
const char *scope) {
notify(ResponseCode::InterfaceAddressChange,
"Address %s %s %s %s %s",
- (action == NetlinkEvent::NlActionAddressUpdated) ? kUpdated : kRemoved,
- addr, iface, flags, scope);
+ (action == NetlinkEvent::NlActionAddressUpdated) ?
+ "updated" : "removed", addr, iface, flags, scope);
}
void NetlinkHandler::notifyInterfaceDnsServers(const char *iface,
@@ -175,15 +164,3 @@
notify(ResponseCode::InterfaceDnsInfo, "DnsInfo servers %s %s %s",
iface, lifetime, servers);
}
-
-void NetlinkHandler::notifyRouteChange(int action, const char *route,
- const char *gateway, const char *iface) {
- notify(ResponseCode::RouteChange,
- "Route %s %s%s%s%s%s",
- (action == NetlinkEvent::NlActionRouteUpdated) ? kUpdated : kRemoved,
- route,
- *gateway ? " via " : "",
- gateway,
- *iface ? " dev " : "",
- iface);
-}