From 6f6d673cc5aa647a25afb9a5048f5045d7f8a1d8 Mon Sep 17 00:00:00 2001 From: Christopher Faylor Date: Wed, 20 Aug 2003 05:15:33 +0000 Subject: * sigproc.cc (wait_sig): Ensure that myself->getsigtodo array is flushed on a __SIGFLUSH. Christopher Faylor * exceptions.cc (_sigreturn): Handle nested signals without growing the stack. --- winsup/cygwin/exceptions.cc | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'winsup/cygwin/exceptions.cc') diff --git a/winsup/cygwin/exceptions.cc b/winsup/cygwin/exceptions.cc index 537f55e99..034e5605d 100644 --- a/winsup/cygwin/exceptions.cc +++ b/winsup/cygwin/exceptions.cc @@ -1220,13 +1220,14 @@ __asm__ volatile ("\n\ .text \n\ _sigreturn: \n\ addl $4,%%esp # Remove argument \n\ - movl %%esp,%%ebp \n\ - addl $36,%%ebp \n\ call _set_process_mask@4 \n\ \n\ cmpl $0,%4 # Did a signal come in? \n\ jz 1f # No, if zero \n\ - call _call_signal_handler_now@0 # yes handle the signal \n\ + movl %2,%%eax \n\ + movl %%esp,%%ebp \n\ + movl %%eax,36(%%ebp) # Restore return address \n\ + jmp 3f \n\ \n\ 1: popl %%eax # saved errno \n\ testl %%eax,%%eax # Is it < 0 \n\ @@ -1257,7 +1258,7 @@ _sigdelayed0: \n\ pushl %%ebx \n\ pushl %%eax \n\ pushl %6 # saved errno \n\ - pushl %3 # oldmask \n\ +3: pushl %3 # oldmask \n\ pushl %4 # signal argument \n\ pushl $_sigreturn \n\ \n\ -- cgit v1.2.3