{
CAPollReturned(readFds, ret);
}
+ else if (ret == 0)
+ {
+ usleep(1000); /* Incase of failure of FastShutdownMechanism timeout will be set to 1.
+ some of the fields are not set by kernel on repeatedly calling
+ poll.Applying a sleep will solve this by providing a delay
+ between each subsequent poll system call */
+ }
else if (ret < 0)
{
OIC_LOG_V(FATAL, TAG, "poll error %s", CAIPS_GET_ERROR);
// Write end of the pipe is closed. Indicates the termination of UDP server.
return;
}
-
- counter++;
}
+ counter++;
+
if (!caglobals.ip.terminate &&
(caglobals.ip.netlinkFd != OC_INVALID_SOCKET) && readFds[counter].revents != 0)
{
else if (ret == 0)
{
usleep(1000); /* some of the fields are not set by kernel on repeatedly calling
- poll.Applying a timeout will solve this*/
+ poll.Applying a sleep will solve this by providing a delay between
+ each subsequent poll system call */
}
else if (ret < 0)
{