diff options
author | Karel Zak | 2014-01-24 13:04:14 +0100 |
---|---|---|
committer | Karel Zak | 2014-01-24 13:04:14 +0100 |
commit | a5bd7939961aaa6e39f3b298e556063cfd97d75a (patch) | |
tree | c7b5425996072f268f5cbb6c5496a4a2a95a5256 /COPYING | |
parent | flock: Change the 'exit status' man page section to make more sense (diff) | |
download | kernel-qcow2-util-linux-a5bd7939961aaa6e39f3b298e556063cfd97d75a.tar.gz kernel-qcow2-util-linux-a5bd7939961aaa6e39f3b298e556063cfd97d75a.tar.xz kernel-qcow2-util-linux-a5bd7939961aaa6e39f3b298e556063cfd97d75a.zip |
include/c.h: prefer nanosleep() over usleep()
Let's use nanosleep() although if usleep() exists. The nanosleep
function does no interact with signals and other timers.
The patch introduces xusleep() as replacement to libc (or our fallback)
usleep(). Yes, we don't want to use struct timespec + nanosleep()
everywhere in code as nano-time resolution is useless for us.
The patch also enlarges delays in some busy wait loops. It seems
enough to try read/write 4x per second.
Signed-off-by: Karel Zak <kzak@redhat.com>
Diffstat (limited to 'COPYING')
0 files changed, 0 insertions, 0 deletions