thanks for the really good explanation of this Martin I'm going to open a report with debian and talk to the author about this. --- TS http://www.southofheaven.org/ Life begins and ends with chaos, live between the chaos!
On 2013-11-01, at 5:15 AM, Martin Costabel <costa...@wanadoo.fr> wrote: > On 1/11/13 02:10, TheSin wrote: >> shouldn't get text have a fallback or maybe we should create one, this type >> of thing is going to cause issue all over, and setting it to N or not >> translate isn't really a good solution. Maybe get text needs to have a >> fallback added to it instead? > > I don't think we can do much about the behavior of gettext. As long as it > uses the CoreFoundation framework, it will not be "async-signal safe", so it > must not be used in the child process after a 'fork' and before 'exec'. This > is documented in many places. > > After reading some of the docs, I find it rather astonishing that dpkg did > not crash before. That it crashes when LANG is unset is less surprising than > that it does not crash when LANG is set and that it waited until OSX 10.8 or > 10.9 to show the crash, but understanding what the precise mechanism of the > crash is would require a deep understanding of CoreFoundation's innards. > > I think that these are real programming errors in dpkg and tar. They should > not use any '_("")' type strings in the child process after 'fork'. If they > really want to transmit localized messages as parameters to some function in > the child process, they should evaluate the string *before* the 'fork' and > transmit a variable to the function, like so: > > --- dpkg-deb/extract.c~ 2013-11-01 11:28:21.000000000 +0100 > +++ dpkg-deb/extract.c 2013-11-01 11:30:51.000000000 +0100 > @@ -244,5 +244,7 @@ > m_pipe(p1); > + char* failedtowrite = _("failed to write to pipe in copy"); > if (!(c1= m_fork())) { > close(p1[0]); > - stream_fd_copy(ar, p1[1], memberlen, _("failed to write to pipe in > copy")); > + stream_fd_copy(ar, p1[1], memberlen, failedtowrite); > if (close(p1[1]) == EOF) ohshite(_("failed to close pipe in copy")); > > -- > Martin > > > > > ------------------------------------------------------------------------------ Android is increasing in popularity, but the open development platform that developers love is also attractive to malware creators. Download this white paper to learn more about secure code signing practices that can help keep Android apps secure. http://pubads.g.doubleclick.net/gampad/clk?id=65839951&iu=/4140/ostg.clktrk _______________________________________________ Fink-devel mailing list Fink-devel@lists.sourceforge.net List archive: http://news.gmane.org/gmane.os.apple.fink.devel Subscription management: https://lists.sourceforge.net/lists/listinfo/fink-devel