invalid equals(), comparing different object types

Change-Id: I2a75955fec042c2ed2a8848628c8b20d039e26c4
diff --git a/protocols/ospf/ctl/src/main/java/org/onosproject/ospf/controller/area/OspfAreaImpl.java b/protocols/ospf/ctl/src/main/java/org/onosproject/ospf/controller/area/OspfAreaImpl.java
index 0738787..540f082 100644
--- a/protocols/ospf/ctl/src/main/java/org/onosproject/ospf/controller/area/OspfAreaImpl.java
+++ b/protocols/ospf/ctl/src/main/java/org/onosproject/ospf/controller/area/OspfAreaImpl.java
@@ -668,7 +668,7 @@
                         }
                     }
                 }
-                if (recLsa.advertisingRouter().equals((String) neighborIP)) {
+                if (recLsa.advertisingRouter().toString().equals((String) neighborIP)) {
                     continue;
                 }
                 if ((recLsa.lsType() == OspfParameters.LINK_LOCAL_OPAQUE_LSA ||
diff --git a/protocols/ospf/ctl/src/main/java/org/onosproject/ospf/controller/impl/TopologyForDeviceAndLinkImpl.java b/protocols/ospf/ctl/src/main/java/org/onosproject/ospf/controller/impl/TopologyForDeviceAndLinkImpl.java
index 67edc39..ca890ac 100644
--- a/protocols/ospf/ctl/src/main/java/org/onosproject/ospf/controller/impl/TopologyForDeviceAndLinkImpl.java
+++ b/protocols/ospf/ctl/src/main/java/org/onosproject/ospf/controller/impl/TopologyForDeviceAndLinkImpl.java
@@ -411,7 +411,7 @@
 
         while (iterator.hasNext()) {
             Ip4Address secondValue = (Ip4Address) iterator.next();
-            if (!value.equals("0.0.0.0")) {
+            if (!value.toString().equals("0.0.0.0")) {
                 if ((!value.equals(secondValue))) {
                     if ((!secondValue.equals(ospfArea.routerId()))) {
                         String key = "link:" + value.toString() + "-" + secondValue.toString();