I have some function as
func1()
{
while (true)
{
isdateok()
{ // return true or false
}
}
}
I want isdateok() should execute till 5 secs (or any timeout which is configured)
if it returns true before the timeout then ok else continue and after 5 secs(or timeout) it should stop processing and return as timeout.
I’m not sure I have understood your question, however the answer should be the following: