diff options
Diffstat (limited to '')
-rw-r--r-- | cpukit/posix/src/psignalclearsignals.c | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/cpukit/posix/src/psignalclearsignals.c b/cpukit/posix/src/psignalclearsignals.c index 480ba51b70..4143d53ec9 100644 --- a/cpukit/posix/src/psignalclearsignals.c +++ b/cpukit/posix/src/psignalclearsignals.c @@ -61,8 +61,8 @@ bool _POSIX_signals_Clear_signals( else signals_blocked = SIGNAL_ALL_MASK; - /* XXX this is not right for siginfo type signals yet */ - /* XXX since they can't be cleared the same way */ + /* XXX is this right for siginfo type signals? */ + /* XXX are we sure they can be cleared the same way? */ _ISR_Disable( level ); if ( is_global ) { @@ -71,6 +71,11 @@ bool _POSIX_signals_Clear_signals( psiginfo = (POSIX_signals_Siginfo_node *) _Chain_Get_unprotected( &_POSIX_signals_Siginfo[ signo ] ); _POSIX_signals_Clear_process_signals( signo ); + /* + * It may be impossible to get here with an empty chain + * BUT until that is proven we need to be defensive and + * protect against it. + */ if ( psiginfo ) { *info = psiginfo->Info; _Chain_Append_unprotected( |