OSDN Git Service

NetlinkHandler: Revert the special handling of event param name.
authorAshish Sharma <ashishsharma@google.com>
Wed, 12 Feb 2014 19:53:00 +0000 (11:53 -0800)
committerAshish Sharma <ashishsharma@google.com>
Wed, 12 Feb 2014 19:53:00 +0000 (11:53 -0800)
The kernel change was reverted to remain consistent with past API.

Change-Id: I60a539aaf3bd78a56ab54391685f6aaf07de19ce

NetlinkHandler.cpp

index 534f386..7edd190 100644 (file)
@@ -91,12 +91,8 @@ void NetlinkHandler::onEvent(NetlinkEvent *evt) {
 
     } else if (!strcmp(subsys, "xt_idletimer")) {
         int action = evt->getAction();
-        const char *label = evt->findParam("LABEL");
+        const char *label = evt->findParam("INTERFACE");
         const char *state = evt->findParam("STATE");
-        // if no LABEL, use INTERFACE instead
-        if (label == NULL) {
-            label = evt->findParam("INTERFACE");
-        }
         if (state)
             notifyInterfaceClassActivity(label, !strcmp("active", state));