change netlink interface flags to addr flags
which used for detect network IPv4/6 changed
Change-Id: I827db082879aafdc3e8bd688917180af09531ab2
Signed-off-by: bg.chun <bg.chun@samsung.com>
Reviewed-on: https://gerrit.iotivity.org/gerrit/15595
Reviewed-by: Hyuna Jo <hyuna0213.jo@samsung.com>
Tested-by: jenkins-iotivity <jenkins-iotivity@opendaylight.org>
Reviewed-by: Phil Coval <philippe.coval@osg.samsung.com>
Reviewed-by: Jaehong Jo <jaehong.jo@samsung.com>
Reviewed-by: Dan Mihai <Daniel.Mihai@microsoft.com>
Reviewed-by: jihwan seo <jihwan.seo@samsung.com>
Reviewed-by: Ashok Babu Channa <ashok.channa@samsung.com>
%define TARGET_TRANSPORT IP
%endif
+%if "%{TARGET_OS}" == "tizen"
+%define TARGET_TRANSPORT IP
+%endif
+
%define JOB "-j4"
%if 0%{?speedpython}
%define JOB %{?_smp_mflags}
for (struct nlmsghdr *nh = (struct nlmsghdr *)buf; NLMSG_OK(nh, len); nh = NLMSG_NEXT(nh, len))
{
- if (nh != NULL && nh->nlmsg_type != RTM_NEWLINK)
+ if (nh != NULL && (nh->nlmsg_type != RTM_DELADDR && nh->nlmsg_type != RTM_NEWADDR))
{
continue;
}
struct ifinfomsg *ifi = (struct ifinfomsg *)NLMSG_DATA(nh);
-
- if ((!ifi || (ifi->ifi_flags & IFF_LOOPBACK) || !(ifi->ifi_flags & IFF_RUNNING)))
+ if (!ifi)
{
continue;
}
int ifiIndex = ifi->ifi_index;
iflist = CAIPGetInterfaceInformation(ifiIndex);
-
if (!iflist)
{
OIC_LOG_V(ERROR, TAG, "get interface info failed: %s", strerror(errno));