Re: [gtk-list] Re: "Common problems" part of FAQ?





On Tue, 16 Sep 1997, Michael K. Johnson wrote:
> Szekeres Istvan writes:
> >The exit() vs _exit() problem is described in the Unix Programming FAQ.
> 
> Oh, I know.  That's why I blushed when I realized what was happening;
> I ought to know better.  I *do* know better if I think about it.  It
> was a cut-n-paste error on my part.
> [snip]
> How can I say this: starting from the answer, the question-answer link
> is painfully obvious.  But if someone is asking the question at all,
> the link isn't obvious.  What I'm suggesting is those links.  So from
> a coding what-ought-I-to-do basis, the Unix FAQ is quite correct.  But
> from a debugging I-already-screwed-up point of view, the Unix FAQ on
> this point is worthless -- if I knew to read that answer, I wouldn't
> need to be reading it.
> 
> Arbitrary Unix programs with this bug will see it in different ways,
> too.  Scrambled data files, arbitrary segfaults in C++ code, random
> other bugs caused by atexit() stuff.  But gtk programs, like all X
> programs, are likely to see it in the particular way I mention above.
> And so, since gtk is some people's introduction to X programming, I'm
> suggesting that this particular manifestation of this general bug be
> mentioned.

(At least) this fea^H^H^Hbug can be avoided by a general g_daemon() function
in glib, which implements the fork();[setsid()], _exit() calls. This would
also be useful to avoid #ifdef HAVE_SETSID & co. in non-library code.


Pista



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