coreutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Bug-tar] Crash in gettext() after fork() on Mac OS X


From: Eric Blake
Subject: Re: [Bug-tar] Crash in gettext() after fork() on Mac OS X
Date: Sat, 23 Nov 2013 11:24:00 -0700
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.1.0

On 11/23/2013 11:12 AM, Pádraig Brady wrote:
> So in summary we're restricted in what we can call
> between fork() and exec() in the child of a multithreaded program.

Between fork() and either exec() or _exit().

> A very quick look at sort.c suggests that that is only
> the _("dup2 failed") call we have to worry about.
> dup2() itself is async-signal-safe according to POSIX.
> I'd just remove the _("") in that case.

That's a malloc taken in the (successful) exec() path; but we also have
calls to _() if exec failed which are also unsafe and need scrubbing.

-- 
Eric Blake   eblake redhat com    +1-919-301-3266
Libvirt virtualization library http://libvirt.org

Attachment: signature.asc
Description: OpenPGP digital signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]