Threaded application sleeps with other application
- by DeeD
I have a weird problem with my threaded software.
I start 2 instances of the software. Each instance has 2 threads, one thread creates a socket to use, and the other one is uses the socket for communication.
When one of the threads in one instance calls sleep(3), the other threads in the the other instance sleeps too. And the weirdest thing is that when I rebooted the computer, it works the first time, but after trying a second time, it sleeps like described.
How is this possible? Is it using some shared resource?