Fix prototype of sleep() and move it to unistd.h

This commit is contained in:
Michael Brown
2006-12-20 03:14:59 +00:00
parent 1e322d4b4c
commit 637a891264
3 changed files with 5 additions and 3 deletions

View File

@@ -75,12 +75,13 @@ int32_t random(void)
/**************************************************************************
SLEEP
**************************************************************************/
void sleep(int secs)
unsigned int sleep(unsigned int secs)
{
unsigned long tmo;
for (tmo = currticks()+secs*TICKS_PER_SEC; currticks() < tmo; ) {
}
return 0;
}
/**************************************************************************
@@ -89,7 +90,7 @@ INTERRUPTIBLE SLEEP
void interruptible_sleep(int secs)
{
printf("<sleep>\n");
return sleep(secs);
sleep(secs);
}
/**************************************************************************