From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 1792) id A96E93848407; Tue, 27 Jul 2021 00:06:03 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org A96E93848407 Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: Samuel Thibault To: glibc-cvs@sourceware.org Subject: [glibc] hurd: _Fork: unlock malloc before calling fork child hooks X-Act-Checkin: glibc X-Git-Author: Samuel Thibault X-Git-Refname: refs/heads/master X-Git-Oldrev: ddcc612ce923038b867083a0c55d6e034951155a X-Git-Newrev: de2f68c3c751df1925c50ebf3be1c9d9f79b1dcf Message-Id: <20210727000603.A96E93848407@sourceware.org> Date: Tue, 27 Jul 2021 00:06:03 +0000 (GMT) X-BeenThere: glibc-cvs@sourceware.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Glibc-cvs mailing list List-Unsubscribe: , List-Archive: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 27 Jul 2021 00:06:03 -0000 https://sourceware.org/git/gitweb.cgi?p=glibc.git;h=de2f68c3c751df1925c50ebf3be1c9d9f79b1dcf commit de2f68c3c751df1925c50ebf3be1c9d9f79b1dcf Author: Samuel Thibault Date: Tue Jul 27 02:03:01 2021 +0200 hurd: _Fork: unlock malloc before calling fork child hooks The setitimer fork hook, fork_itimer, needs to call malloc inside __mach_setup_tls, so we need to unlock malloc before calling it. Diff: --- sysdeps/mach/hurd/_Fork.c | 1 + 1 file changed, 1 insertion(+) diff --git a/sysdeps/mach/hurd/_Fork.c b/sysdeps/mach/hurd/_Fork.c index 75d45d6cad..88787f35ac 100644 --- a/sysdeps/mach/hurd/_Fork.c +++ b/sysdeps/mach/hurd/_Fork.c @@ -660,6 +660,7 @@ retry: /* Release malloc locks. */ _hurd_malloc_fork_child (); + call_function_static_weak (__malloc_fork_unlock_child); /* Run things that want to run in the child task to set up. */ RUN_HOOK (_hurd_fork_child_hook, ());