mirror of
git://sourceware.org/git/glibc.git
synced 2025-02-17 13:00:43 +08:00
* stdlib/tst-setcontext.c: Catch the case where the links gets
messed up and we do not reach main again.
This commit is contained in:
parent
9e80c1231e
commit
d90d025691
@ -1,5 +1,8 @@
|
||||
2007-12-03 Ulrich Drepper <drepper@redhat.com>
|
||||
|
||||
* stdlib/tst-setcontext.c: Catch the case where the links gets
|
||||
messed up and we do not reach main again.
|
||||
|
||||
* po/ca.po: Update from translation team.
|
||||
|
||||
2007-11-26 Ulrich Drepper <drepper@redhat.com>
|
||||
|
@ -123,9 +123,26 @@ test_stack(volatile int a, volatile int b,
|
||||
|
||||
volatile int global;
|
||||
|
||||
|
||||
static int back_in_main;
|
||||
|
||||
|
||||
static void
|
||||
check_called (void)
|
||||
{
|
||||
if (back_in_main == 0)
|
||||
{
|
||||
puts ("program did no reach main again");
|
||||
_exit (1);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
int
|
||||
main (void)
|
||||
{
|
||||
atexit (check_called);
|
||||
|
||||
char st1[32768];
|
||||
|
||||
puts ("making contexts");
|
||||
@ -185,6 +202,7 @@ main (void)
|
||||
exit (1);
|
||||
}
|
||||
puts ("back at main program");
|
||||
back_in_main = 1;
|
||||
|
||||
if (was_in_f1 == 0)
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user