On 3/21/2023 3:11 PM, Petro Karashchenko wrote:
I've counted 28 signals specified in
https://pubs.opengroup.org/onlinepubs/9699919799/basedefs/signal.h.html  and
2 (SIGUSR1 and SIGUSR2) are already reserved for application needs. So 31 -
(28 - 2) == 5. One signal value is "reserved" for SIGWORK, so it makes 4
signal values that can be used by application without any questions.

The real time signals are all sequentially numbered starting at SIGRTMIN and going through SIGRTMAX.

I see another error.  The standard signals are also in the range of SIGRTMIN through  SIGRTMAX.  It should not be

  #define SIGRTMIN        MIN_SIGNO /* First real time signal */
  #define SIGRTMAX        MAX_SIGNO       /* Last real time signal */

It should be:

  #define SIGRTMIN        (SIGIO + 1) /* First real time signal */
  #define SIGRTMAX        MAX_SIGNO       /* Last real time signal */

Per POSIX (https://pubs.opengroup.org/onlinepubs/7908799/xsh/signal.h.html):

   This header also declares the macros SIGRTMIN and SIGRTMAX, which
   evaluate to integral expressions and, if the Realtime Signals
   Extension option is supported, specify a range of signal numbers
   that are reserved for application use and for which the realtime
   signal behaviour specified in this specification is supported. The
   signal numbers in this range do not overlap any of the signals
   specified in the following table.

   The range SIGRTMIN through SIGRTMAX inclusive includes at least
   RTSIG_MAX signal numbers.

I will update the Issue to include this problem too.

Reply via email to