* assert broken?
@ 2011-02-17 18:49 Stan
2011-02-17 19:05 ` Larry Hall (Cygwin)
2011-02-19 18:32 ` Warren Young
0 siblings, 2 replies; 3+ messages in thread
From: Stan @ 2011-02-17 18:49 UTC (permalink / raw)
To: cygwin
I've run cygcheck and tried this on two systems with the same
results; at this point I'm assuming the problem is not local so I'm
not including the typically requested data. I will be glad to follow
up if my assumption turns out to be incorrect.
The issue is triggering an assert dumps core. Trivial test case:
#include <assert.h>
int main()
{
assert(1==0);
return 1;
}
causes a core dump. I originally noticed this is a gdb session and the
triggered assert leaves a bt showing windows info so it looks like the
stack unwinding is having a bad day.
--
Problem reports: http://cygwin.com/problems.html
FAQ: http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: assert broken?
2011-02-17 18:49 assert broken? Stan
@ 2011-02-17 19:05 ` Larry Hall (Cygwin)
2011-02-19 18:32 ` Warren Young
1 sibling, 0 replies; 3+ messages in thread
From: Larry Hall (Cygwin) @ 2011-02-17 19:05 UTC (permalink / raw)
To: cygwin
On 2/17/2011 1:49 PM, Stan wrote:
>
> I've run cygcheck and tried this on two systems with the same
> results; at this point I'm assuming the problem is not local so I'm
> not including the typically requested data. I will be glad to follow
> up if my assumption turns out to be incorrect.
>
> The issue is triggering an assert dumps core. Trivial test case:
>
> #include<assert.h>
>
> int main()
> {
> assert(1==0);
> return 1;
> }
>
> causes a core dump. I originally noticed this is a gdb session and the
> triggered assert leaves a bt showing windows info so it looks like the
> stack unwinding is having a bad day.
When an assertion fails, it calls abort().
<http://pubs.opengroup.org/onlinepubs/009695399/functions/assert.html>
Are you saying it's not doing this?
--
Larry
_____________________________________________________________________
A: Yes.
> Q: Are you sure?
>> A: Because it reverses the logical flow of conversation.
>>> Q: Why is top posting annoying in email?
--
Problem reports: http://cygwin.com/problems.html
FAQ: http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: assert broken?
2011-02-17 18:49 assert broken? Stan
2011-02-17 19:05 ` Larry Hall (Cygwin)
@ 2011-02-19 18:32 ` Warren Young
1 sibling, 0 replies; 3+ messages in thread
From: Warren Young @ 2011-02-19 18:32 UTC (permalink / raw)
To: Cygwin-L
On 2/17/2011 11:49 AM, Stan wrote:
>
> The issue is triggering an assert dumps core.
It's supposed to. The core gets you a backtrace, the exact line of code
which tripped the assertion (you can't always tell just from the text of
the assert()), the state of variables, etc. This is a very good thing;
we wouldn't want it any other way.
--
Problem reports: http://cygwin.com/problems.html
FAQ: http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2011-02-19 18:32 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-02-17 18:49 assert broken? Stan
2011-02-17 19:05 ` Larry Hall (Cygwin)
2011-02-19 18:32 ` Warren Young
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).