View Single Post
  #3  
Old 11-13-2009, 08:20 AM
erde
Sarnak
 
Join Date: Sep 2006
Location: Germany
Posts: 82
Default

Ok, after a bit of reading Sleep should look like this:

Code:
void Sleep(unsigned int x) {
        if (x <= 0  )
                return;
        if ( x>=1000 )
                sleep(x/1000);
        else
                usleep(x*1000);
}
From the man page:
Quote:
The useconds argument must be less than 1,000,000. If the value of useconds is 0, then the call has no effect.
Found here: Source
__________________
"Yes, the artwork is awful. I am an engineer, not an artist " - David H. Eberly
Reply With Quote