[LCP]Help in Threads

Mohd Saifullah saif at lantana.tenet.res.in
Wed Nov 20 13:21:02 UTC 2002


Greetings to All!

I have written two threads (Linux pthreads). One thread does "ping"ing for
two to three secs. The other thread has to note down the interface traffic
count at the beginning of the pinging and also at the end of it, so this
thread has 2 secs sleep in between the two readings. But the problem is:  
first thread is executed completely and then control comes to second 
thread. But i want control to switch from first thread to second thread as
soon as first one starts pinging.

Thanks in advance,
Saif




More information about the linuxCprogramming mailing list