This is the mail archive of the
mailing list for the Cygwin project.
Re: Cygwin coreutils assertion failed
- From: Eric Blake <ebb9 at byu dot net>
- To: Daniel <danengel1 at gmail dot com>, cygwin at cygwin dot com
- Date: Fri, 03 Aug 2007 07:17:05 -0600
- Subject: Re: Cygwin coreutils assertion failed
- References: <firstname.lastname@example.org>
- Reply-to: cygwin at cygwin dot com
-----BEGIN PGP SIGNED MESSAGE-----
http://cygwin.com/acronyms/#PPIOSPE - redirecting to the list.
According to Daniel on 8/3/2007 12:29 AM:
> Hi Eric,
> I'm running Windows XP Professional with Cygwin 2.510.2.2.
No, you aren't. You loaded cygwin using setup.exe version 2.510.2.2, but
cygwin itself is at version 1.5.24. Also, coreutils is now at 6.9-4,
while you only have 6.9-3; you may want to consider upgrading.
> I have a
> tail -n 1000 -F -s 0.1 ~/putty.log
> running all the time since many weeks. Tonight it crashed with the message:
> assertion "0 <= seconds" failed: file
> line 57
> bash: [3120: 1] tcsetattr: Inappropriate ioctl for device
Well, calling xnanosleep with negative time (where seconds is a variable
of type double) certainly implies a bug. The question is why the time was
Even worse, in the source for tail, xnanosleep is called in only one
place, inside a while(1) loop, with a value initialized to 0.1 outside of
the loop by your choice of -s option but never assigned within the loop.
It is either stack corruption (perhaps due to faulty memory), or else the
double sleep value is being stored only in a register and the register is
not properly being restored after some context switch. Without
disassembling tail, I don't know whether the sleep_interval was stored on
the stack or in a register; but since it is the only use of floating point
in tail.c, I would suspect that the compiler did not need to spill it out
of registers onto the stack. Either way, it does not sound like a
pleasant bug, nor does it seem like something that is caused directly by
Don't work too hard, make some time for fun as well!
Eric Blake email@example.com
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.5 (Cygwin)
Comment: Public key at home.comcast.net/~ericblake/eblake.gpg
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
-----END PGP SIGNATURE-----
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Problem reports: http://cygwin.com/problems.html