On Fri, May 23, 2008 at 01:31:58PM +0200, Joerg Barfurth wrote: > Hi, > > I just stumbled over this: > > Edward Pilatowicz schrieb: >> - nit: in start_zoneadmd(), instead of: >> if ((child_pid = fork()) == -1) { >> zperror(gettext("could not fork")); >> goto out; >> } else if (child_pid == 0) { >> ... >> _exit(1); >> } else { >> ... >> } >> how about: >> if ((child_pid = fork()) == -1) { >> zperror(gettext("could not fork")); >> goto out; >> } >> >> if (child_pid == 0) { >> ... >> _exit(1); >> } >> >> ... >> >> - nit: we have direct bindings now. :) so why bother with: >> _exit(1) >> instead just call: >> exit(1) >> > > Beware: _exit() is not just a linker synonym for exit(). See the exit(2) > man page for differences. When fork-ing without exec, calling _exit is the > proper way to exit; see the Notes section in the fork(2) man page. >
yeah. i've educated myself with the man pages. earlier i just saw the leading '_' and assumed that _exit() was just a linker synonym. thanks ed _______________________________________________ zones-discuss mailing list zones-discuss@opensolaris.org