Displaying 20 results from an estimated 379 matches for "usleep".
Did you mean:
sleep
2011 Oct 03
2
patch: Replace many usleep and some sleep calls with nanosleep
Description: Replace many usleep and some sleep calls with nanosleep.
usleep is stated in its manual page as removed by POSIX.
Contrary to its predecessors, nanosleep semantics is well
defined. The replacement, which is mostly in drivers, is
untested. Supplements http://bugs.debi...
2020 Mar 27
2
[Bug 14328] New: usleep() is obsolete, use nanosleep()
https://bugzilla.samba.org/show_bug.cgi?id=14328
Bug ID: 14328
Summary: usleep() is obsolete, use nanosleep()
Product: rsync
Version: 3.1.3
Hardware: All
OS: All
Status: NEW
Severity: normal
Priority: P5
Component: core
Assignee: wayne at opencoder.net
Reporter: devzer...
2009 Jun 10
0
[PATCH] Use nanosleep instead of usleep when waiting the hardware.
usleep() was being used without checking its return value. When the
server receives SIGALRM or SIGIO the waits are shortened and random
modesetting failures happen: Use nanosleep and loop around it until
the requested time has elapsed.
---
src/nouveau_hw.c | 2 +-
src/nouveau_local.h | 6 ++++++...
2004 May 08
1
500ms usleep in rtp.c ?
http://bugs.digium.com/bug_view_page.php?bug_id=0001589
Has anyone else heard an audible blip, break or garble between answer and the native bridge attempt using sip?
If I change the usleep(500000); to usleep(5000); in rtp.c the proble totally goes away... even the note above it says it needs to be fixed.
bkw
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.digium.com/pipermail/asterisk-users/attachments/20040509/9d2ea0f8/attachment.htm
2010 Dec 16
3
windows_port NUT branch
Hi,
Frederic, big thanks for your work on this, by a coincedence it's exactly what
i need at work :)
I'm compiling your branch on Debian GNU/Linux with mingw and having some minor
troubles worth mentioning and (i hope) fixing.
I configure with
CC=586-mingw32msvc-gcc ./configure --host=i586-mingw32msvc --prefix=/c/winnut/
Interestingly, there's scripts/Windows/Makefile in the repo
2020 Apr 04
0
[PATCH] nonblocking: remove usleep usage
usleep is deprecated under POSIX 2008 and is optionally unavailable
with uClibc-ng.
Signed-off-by: Rosen Penev <rosenp at gmail.com>
---
examples/nonblocking.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/examples/nonblocking.c b/examples/nonblocking.c
index 8e38a94..2f15...
2007 Sep 03
2
[git patch] minor fixes
...am include grp.h
[klibc] getpwnam, getpwuid include pwd.h
[klibc] ctype.h declare char classification functions
[klibc] do_mounts_md.c include kinit.h
[klibc] strtotimex include time.h
[klibc] add some specific .gitignore
[klibc] qsort, sleep, strntoumax, strtox, usleep include stdlib.h
and diffstat
klcc/.gitignore | 2 ++
scripts/basic/.gitignore | 1 +
usr/include/ctype.h | 16 ++++++++++++++++
usr/include/grp.h | 2 ++
usr/include/klibc/.gitignore | 1 +
usr/kinit/do_mounts_md.c | 1 +
usr/klibc/qsort...
2006 Mar 10
0
IMQ strange problem
...64 X2 Dual Core Processor 3800+
MemTotal: 1036332 k
Linux portal1 2.6.15.4 #1 SMP Sun Feb 12 13:02:52 EET 2006 i686 GNU/Linux
IMQ patch: linux-2.6.14-imq6.diff
/// traffic control rules for download and upload single IP
.............
DEV=eth1
DEV_UP=imq0
.................
.................
usleep 10
$TC class add dev $DEV parent 2:3 classid 2:b382 htb rate 2048kbit ceil
2048kbit prio 2 quantum 48000
$TC class add dev $DEV parent 3:1 classid 3:a382 htb rate 160kbit ceil
160kbit prio 1 quantum 16000
$TC class add dev $DEV parent 4:10 classid 4:d382 htb rate 2048kbit ceil
2048kbit prio 3 quant...
2011 Nov 13
0
[LLVMdev] Thumb-2 code generation error in Apple LLVM at all optimization levels
...achine code generated by Apple's
LLVM 3.0+svn compiler is correct, but that when a Release build is
generated, the use of conditional machine instructions confuses GDB.
I boiled my apparently erroneous source down to:
- (void) mySleep: (int)sleepTime
{
if ( sleepTime >= 4000 ){
usleep( sleepTime );
}
return;
}
If I set a breakpoint on the usleep call, the breakpoint will be hit
but usleep() will not actually be called.
I verified this by passing in 5000. When I do, I can step down into
the shared libraries that lead to the actual system call.
I have also tried call...
2011 Nov 12
2
[LLVMdev] Thumb-2 code generation error in Apple LLVM at all optimization levels
...> The IT instruction is how you express predication in Thumb2. Unlike ARM instructions, where the predicate is part of the instruction, Thumb2 instructions use IT to set the predicates for following instructions. In this case, it applies the "hs" predicate to the subsequent call to _usleep. I'd have to double check, but I'm fairly confident that the hs condition code is equivalent to >= for integers.
All of my regression testing so far has had my speed slider set to its
maximum, so the useconds_t has always been precisely zero.
Maybe there's something special about...
2014 Nov 17
2
Bug-report:rsync may hung if time jumps backwards
...E. (In the future it might return FALSE if
* interrupted.)
**/
+
int msleep(int t)
{
+
+#if 0
int tdiff = 0;
struct timeval tval, t1, t2;
@@ -1192,7 +1195,8 @@
tdiff = (t2.tv_sec - t1.tv_sec)*1000 +
(t2.tv_usec - t1.tv_usec)/1000;
}
-
+#endif
+ usleep(t*1000);
return True;
}
Is it a correct fix? any comments would be appreciated!!!
-------------- next part --------------
A non-text attachment was scrubbed...
Name: change-time-loop.sh
Type: application/x-sh
Size: 114 bytes
Desc: not available
URL: <http://lists.samba.org/pipermail/...
2003 Jan 15
1
Problem with 'resource temporarily unavailable'
...that rsync thinks the line failed so it waits a minute to retry.
We did use rsync v2.5.5 in one instance to throttle the bandwidth down
to 20KB which worked, but in other locations the problem wouldn't go away.
I've added a delay to meta.c so if it errors out, retry in 1 second
(using usleep(1000)). I also made an it log every time it was going to
retry and if it fails, log the failure. the code looks like this:
if(write(c->socket, bufp, length) < 0) {
syslog(LOG_ERR, _("Sending meta data to %s (%s) failed
will retry is 1000ms"), c->name,...
2011 May 19
2
Scheduling NUT 2.6.1
Fellows,
time has come for a new NUT release: I'm planning on 2.6.1 next week (max
Friday 27), and I'm currently processing remaining patches.
If you have some more on your side, please send in.
cheers,
Arnaud
--
Linux / Unix Expert R&D - Eaton - http://powerquality.eaton.com
Network UPS Tools (NUT) Project Leader - http://www.networkupstools.org/
Debian Developer -
2005 Feb 01
3
X100P Clone
...ce from the PSTN
is not routed thought the SIP channels, you can only hear it in the
modem's speaker.
Does anyone know how to fix the problem...
modified this function in:
/usr/src/asterisk/channels/chan_modem.c
int ast_modem_send(struct ast_modem_pvt *p, char *cmd, int len)
{
int i;
usleep(5000);
if (!len) {
for(i = 0; cmd[i];)
{
if (fwrite(cmd + i,1,1,p->f) != 1)
{
if (errno == EWOULDBLOCK) continue;
return -1;
}
i++;
usleep(5000);
}
tcdrain(...
2014 Dec 06
1
Bug#772274: xen-utils-common: when upgrading package: insserv: Service xenstored has to be enabled to start service xendomains
...an13+nmu1
ii python 2.7.8-2
ii ucf 3.0030
ii udev 215-7
ii xenstore-utils 4.4.1-5
xen-utils-common recommends no packages.
xen-utils-common suggests no packages.
-- Configuration Files:
/etc/default/xendomains changed:
XENDOMAINS_SYSRQ=""
XENDOMAINS_USLEEP=100000
XENDOMAINS_CREATE_USLEEP=5000000
XENDOMAINS_MIGRATE=""
XENDOMAINS_SAVE=""
XENDOMAINS_SHUTDOWN="--wait"
XENDOMAINS_SHUTDOWN_ALL="--all --wait"
XENDOMAINS_RESTORE=false
XENDOMAINS_AUTO=/etc/xen/auto
XENDOMAINS_AUTO_ONLY=true
XENDOMAINS_STOP_MAXWAIT=300...
2014 Nov 28
2
Bug-report:rsync may hung if time jumps backwards
thanks your reply, could you please send off official fix?
On 11/28/2014 04:05 AM, Wayne Davison wrote:
> On Sun, Nov 16, 2014 at 10:44 PM, yhu2 <yadi.hu at windriver.com
> <mailto:yadi.hu at windriver.com>> wrote:
>
> + usleep(t*1000);
> Is it a correct fix? any comments would be appreciated!!!
>
>
> The hang was not because time went backwards, but because it moved
> forward by over 2 years (which overflows a variable, making the value
> negative). I both fixed that issue, and added a configure...
1999 Sep 30
0
non-cpu intensive sleep in R?;
Hi,
Is there a function similar to C's usleep in R?
usleep(10000);
from the man pages:
The usleep() function will cause the calling thread to be suspended from
execution until either the number of real-time microseconds specified by
the argument useconds has elapsed or a signal is delivered to the
calling thread and its action is to invoke...
2018 Dec 20
2
Authentication/Penalty disabled (socket mode=0) introduces constant 5 sec delays (2.27 on debian 9)
...de child
attach 11833
cont
# Send an e-mail from swaks to exim that use transport=smtp in LMTP mode to dovecot-lmtp, press interrupt while exim is blocking after RCPT TO:
(gdb) bt
#0 0x00007f81528af270 in __nanosleep_nocancel () at ../sysdeps/unix/syscall-template.S:84
#1 0x00007f81528d8b84 in usleep (useconds=<optimized out>) at ../sysdeps/posix/usleep.c:32
#2 0x00007f815329368e in net_connect_unix_with_retries (path=0x562dc200ce10 <error: Cannot access memory at address 0x562dc200ce10>, msecs=msecs at entry=5000) at net.c:347
#3 0x00007f815320ce0d in anvil_client_connect (client...
2001 Feb 13
4
issue with EGD in openssh
...dying. get_random_bytes() also needs to check for EPIPE and
reconnect to the daemon if it gets that.
2) If there are currently SOMAXCONN connections to the entropy
daemon, further ones will return ECONNREFUSED. It seems like
some kind of connect || sleep loop is needed here. I used
usleep() which not all OSes support. I've included the usleep.c
from OpenBSD which uses nanosleep() but since not every OS has
that either, a version using select() should probably be used
when the OS has no nanosleep. Also, the sleep is for only
a total of 1 second before giving up. Pe...
2019 Sep 06
2
[PATCH 08/18] virtiofs: Drain all pending requests during ->remove time
..._ON(fsvq->in_flight < 0);
> +
> + /* Wait for in flight requests to finish.*/
> + while (1) {
> + spin_lock(&fsvq->lock);
> + if (!fsvq->in_flight) {
> + spin_unlock(&fsvq->lock);
> + break;
> + }
> + spin_unlock(&fsvq->lock);
> + usleep_range(1000, 2000);
> + }
I think all contexts that call this allow sleeping so we could avoid
usleep here.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 488 bytes
Desc: not available
URL: <http://lists....