[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Avoid C stack overflow
From: |
Dmitry Antipov |
Subject: |
Avoid C stack overflow |
Date: |
Thu, 13 Mar 2014 20:42:52 +0400 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.3.0 |
In http://debbugs.gnu.org/cgi/bugreport.cgi?bug=16999 the user, guided by
interactive
help and documentation, got a crash caused by C stack overflow. What about an
attempt
to avoid such a mess by examining current C stack depth and check it against
system
limits, like suggested in the patch below?
For those who cares about MS-Windows, this looks like a rough equivalent to
getrlimit (RLIMIT_STACK,...):
http://stackoverflow.com/questions/21754928/how-to-get-stack-size-and-stack-limit-of-any-thread-using-win32-api
Dmitry
error_if_c_stack_overflow.patch
Description: Text Data
- Avoid C stack overflow,
Dmitry Antipov <=
- Re: Avoid C stack overflow, Eli Zaretskii, 2014/03/13
- Re: Avoid C stack overflow, Paul Eggert, 2014/03/13
- Re: Avoid C stack overflow, Eli Zaretskii, 2014/03/13
- Re: Avoid C stack overflow, Dmitry Antipov, 2014/03/14
- Re: Avoid C stack overflow, Paul Eggert, 2014/03/14
- Re: Avoid C stack overflow, Dmitry Antipov, 2014/03/14
- Re: Avoid C stack overflow, Stefan Monnier, 2014/03/14
- Re: Avoid C stack overflow, Paul Eggert, 2014/03/14
- Re: Avoid C stack overflow, Stefan, 2014/03/14