sigqueue: add signal type judgment logic

To determine whether a signal is real-time signal or standard signal, the POSIX standard https://www.man7.org/linux/man-pages/man7/signal.7.html defines a real-time signal between SIGRTMIN  and SIGRTMAX , which can store multiple copies, otherwise only one can be retained.

Signed-off-by: xinhaiteng <xinhaiteng@xiaomi.com>
This commit is contained in:
xinhaiteng 2023-08-21 11:03:56 +08:00 committed by Xiang Xiao
parent 630b5f32a2
commit dbefe37a3a
1 changed files with 8 additions and 1 deletions

View File

@ -200,6 +200,13 @@ static FAR sigpendq_t *
DEBUGASSERT(group != NULL);
/* Determining whether a signal is reliable or unreliable */
if (SIGRTMIN <= signo && signo <= SIGRTMAX)
{
return sigpend;
}
/* Pending signals can be added from interrupt level. */
flags = enter_critical_section();