wait_until function calls when the function is not invoked from a loop
that checks whether a condition predicate holds or the function has a
This check corresponds to the CERT C++ Coding Standard rule CON54-CPP. Wrap functions that can spuriously wake up in a loop. and CERT C Coding Standard rule CON36-C. Wrap functions that can spuriously wake up in a loop.