Hi all , I am trying to build a simple pre-emptive userspace thread library using makecontext,getcontext and swapcontext. Is it safe to assign the ucontext_t struct passed in a sighandler with a ucontext_t struct created using getcontext ? I am currently using Redhat Linux 7.3 with gcc 2.96 . If anybody has any idea regarding what can be the potential problem with such usage ? Regards Kshitiz eg. static void handler_sigalrm(int sig ,siginfo_t *sip ,void *arg) { ucontext_t * uap = (ucontext_t *)arg; int x; current_thread = *uap; // current_thread and other_thread are global *uap = other_thread; // object of type ucontext_t } _______________________________________________ Redhat-devel-list mailing list Redhat-devel-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/redhat-devel-list