Mauro Salvini wrote:
> Hi to all,
>
> I would build an application where only one of real-time tasks
> executes a custom signal handler to respond to a set of signals (ex
> SIGINT, SIGTERM). Xenomai tasks are also POSIX threads, so I think
> that at creation they inherits all signal masks and handlers from
> parent thread.
Handlers are per-process, not per-thread.
> So, what I can do in my app is reset signal mask to
> block all signals when new task starts.
Why do this? Why not only mask the signals you want to handle in the
separate thread?
And yes, you must let Xenomai thread handle SIGWINCH
> By the way, is there a method in Xenomai to initialize all RT_TASK
> structure fields without use field names (eg
> PTHREAD_MUTEX_INITIALIZER )? I use this simple define:
Well, as you found out, one of the members of the RT_TASK structure is
the pthread_t identifier of the corresponding thread, so, how do you
figure it would be possible to initialize the RT_TASK in advance before
the thread is even created?
And by the way, POSIX has PTHREAD_MUTEX_INITIALIZER, not
PTHREAD_INITIALIZER. So, you are comparing things which are not really
comparable.
Listen, we do have limited ressources to answer your questions, so
please take time to read some documentation, and think a bit before
asking questions.
--
Gilles.
_______________________________________________
Xenomai-help mailing list
[email protected]
https://mail.gna.org/listinfo/xenomai-help