forked from Imagelibrary/rtems
POSIX timer support modifications.
This commit is contained in:
@@ -34,12 +34,10 @@ int pthread_kill(
|
||||
if ( sig && !is_valid_signo(sig) )
|
||||
set_errno_and_return_minus_one( EINVAL );
|
||||
|
||||
/* commented out when posix timers added
|
||||
if ( _POSIX_signals_Vectors[ sig ].sa_flags == SA_SIGINFO )
|
||||
set_errno_and_return_minus_one( ENOSYS );
|
||||
|
||||
/*
|
||||
* RTEMS does not support sending a siginfo signal to a specific thread.
|
||||
*/
|
||||
*/
|
||||
|
||||
the_thread = _POSIX_Threads_Get( thread, &location );
|
||||
switch ( location ) {
|
||||
|
||||
@@ -22,6 +22,12 @@
|
||||
#include <rtems/posix/seterr.h>
|
||||
#include <rtems/score/isr.h>
|
||||
|
||||
/*
|
||||
* PARAMETERS_PASSING_S is defined in ptimer.c
|
||||
*/
|
||||
|
||||
extern void PARAMETERS_PASSING_S (int num_signal, const struct sigaction inf);
|
||||
|
||||
int sigaction(
|
||||
int sig,
|
||||
const struct sigaction *act,
|
||||
|
||||
@@ -112,6 +112,14 @@ int sigtimedwait(
|
||||
_Thread_queue_Enqueue( &_POSIX_signals_Wait_queue, interval );
|
||||
_Thread_Enable_dispatch();
|
||||
|
||||
/*
|
||||
* When the thread is set free by a signal, it is need to eliminate
|
||||
* the signal.
|
||||
*/
|
||||
|
||||
_POSIX_signals_Clear_signals( api, the_info->si_signo, the_info,
|
||||
FALSE, FALSE );
|
||||
|
||||
errno = _Thread_Executing->Wait.return_code;
|
||||
return the_info->si_signo;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user