Sergey Bugaev, le sam. 15 avril 2023 10:34:46 +0300, a ecrit:
> If you really want to deallocate and reset the current reply port, you
> need to do the dance like sigreturn does:
>
> mach_port_t reply_port = THREAD_GETMEM (THREAD_SELF, reply_port);
> THREAD_SETMEM (THREAD_SELF, MACH_PORT_DEAD);
>
On Sat, Apr 15, 2023 at 9:45 AM Samuel Thibault wrote:
> Sergey Bugaev, le ven. 14 avril 2023 23:29:51 +0300, a ecrit:
> > By the way: that __mig_dealloc_reply_port () inside
> > _dl_sysdep_start_cleanup () is not doing what the author of that code
> > wanted it to do. It deallocates the current r
Hello,
Sergey Bugaev, le ven. 14 avril 2023 23:29:51 +0300, a ecrit:
> On Fri, Apr 14, 2023 at 8:33 PM Samuel Thibault
> wrote:
> > Applied with fixing the __mig_dealloc_reply_port(NULL) cases, thanks!
>
> By the way: that __mig_dealloc_reply_port () inside
> _dl_sysdep_start_cleanup () is not
On Fri, Apr 14, 2023 at 8:33 PM Samuel Thibault wrote:
> Applied with fixing the __mig_dealloc_reply_port(NULL) cases, thanks!
By the way: that __mig_dealloc_reply_port () inside
_dl_sysdep_start_cleanup () is not doing what the author of that code
wanted it to do. It deallocates the current repl
Applied with fixing the __mig_dealloc_reply_port(NULL) cases, thanks!
Sergey Bugaev, le jeu. 13 avril 2023 14:58:12 +0300, a ecrit:
> Now that the signal code no longer accesses it, the only real user of it
> was mig-reply.c, so move the logic for managing the port there.
>
> If we're in SHARED a
Hello,
Sergey Bugaev, le jeu. 13 avril 2023 16:20:50 +0300, a ecrit:
> On Thu, Apr 13, 2023 at 4:12 PM Samuel Thibault
> wrote:
> at ../sysdeps/mach/hurd/dl-sysdep.c:241
> > 241 __mig_dealloc_reply_port (MACH_PORT_NULL);
>
> Uhh, who deallocs a reply port like that :| You can't pass r
On Thu, Apr 13, 2023 at 4:12 PM Samuel Thibault wrote:
at ../sysdeps/mach/hurd/dl-sysdep.c:241
> 241 __mig_dealloc_reply_port (MACH_PORT_NULL);
Uhh, who deallocs a reply port like that :| You can't pass random crap
into __mig_dealloc_reply_port and rely on its particular
implementation,
Sergey Bugaev, le jeu. 13 avril 2023 14:58:12 +0300, a ecrit:
> NOTE: Completely untested! Do your own testing! You have been warned!
Doesn't work :)
(gdb) bt
#0 0x08000db3 in abort () at ../sysdeps/mach/hurd/dl-sysdep.c:753
#1 0x0802328a in __mig_dealloc_reply_port (arg=)
at ../sysdeps/ma
Now that the signal code no longer accesses it, the only real user of it
was mig-reply.c, so move the logic for managing the port there.
If we're in SHARED and outside of rtld, we know that __LIBC_NO_TLS ()
always evaluates to 0, and a TLS reply port will always be used, not
__hurd_reply_port0. St