Sponsored Content
Top Forums Programming Introducing Delay less then a second. Post 52204 by Russell on Monday 14th of June 2004 03:00:18 AM
Old 06-14-2004
Code:
shell% man nanosleep

 

3 More Discussions You Might Find Interesting

1. What is on Your Mind?

Introducing myself... :D

Hey guys, I am Shelby! :-) I am 13 years old and i love Unix. When i was about 6 i was introduced to computers, because almost all of my family is comprised of artists, i used macs at a very early age. I generally sat on the computer until the time i was about 10 when i walked into a laptop store... (2 Replies)
Discussion started by: mesaynaysayer
2 Replies

2. Programming

Introducing a new project for AI lovers

Hi guys, I'm the maintainer of Imperfect world of Robots, and I'm here to introduce this project to any AI lover. This is a free (as in freedom) software and release under the terms of GNU General Public License. Although it belongs to the programming game category, it's not only about... (0 Replies)
Discussion started by: aidin_36
0 Replies

3. What is on Your Mind?

Introducing Myself.

Hello! I didn't see an Introduce Yourself/Meet and Greet board, so I think this might be the right place. I'm a student and a new coder. I run Ubuntu 11.10 currently, and I program in Python, and I'm learning a few languages alongside. Random pages: Twitter - @NihilusV, other links can... (1 Reply)
Discussion started by: NihilusV
1 Replies
NANOSLEEP(2)						      BSD System Calls Manual						      NANOSLEEP(2)

NAME
nanosleep -- suspend process execution for an interval measured in nanoseconds LIBRARY
Standard C Library (libc, -lc) SYNOPSIS
#include <time.h> int nanosleep(const struct timespec *rqtp, struct timespec *rmtp); DESCRIPTION
The nanosleep() system call causes the calling thread to sleep until the time interval specified by rqtp has elapsed. An unmasked signal will cause it to terminate the sleep early, regardless of the SA_RESTART value on the interrupting signal. RETURN VALUES
If the nanosleep() system call returns because the requested time has elapsed, the value returned will be zero. If the nanosleep() system call returns due to the delivery of a signal, the value returned will be -1, and the global variable errno will be set to indicate the interruption. If rmtp is non-NULL, the timespec structure it references is updated to contain the unslept amount (the request time minus the time actually slept). ERRORS
The nanosleep() system call fails if: [EFAULT] Either rqtp or rmtp points to memory that is not a valid part of the process address space. [EINTR] The nanosleep() system call was interrupted by the delivery of a signal. [EINVAL] The rqtp argument specified a nanosecond value less than zero or greater than or equal to 1000 million. [ENOSYS] The nanosleep() system call is not supported by this implementation. SEE ALSO
sigsuspend(2), sleep(3) STANDARDS
The nanosleep() system call conforms to IEEE Std 1003.1b-1993 (``POSIX.1''). BSD
April 17, 1997 BSD
All times are GMT -4. The time now is 09:33 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy