I am creating multiple threads programme using pthread. Is sleep() cause the process ( all the threads) to stop executing or just the thread where I am calling sleep?
Thanks
I am creating multiple threads programme using pthread. Is sleep() cause the process ( all the threads) to stop executing or just the thread where I am calling sleep?
Thanks
Just the thread. The POSIX documentation for sleep() says:
The
sleep()
function shall cause the calling thread to be suspended from execution...