Date: Mon, 11 Feb 2013 19:34:30 +0700 From: Erich Dollansky <erichsfreebsdlist@alogt.com> To: Peter Pentchev <roam@ringlet.net> Cc: freebsd-doc@freebsd.org Subject: Re: missing information in man 3 system Message-ID: <20130211193430.2a7ef6eb@X220.ovitrap.com> In-Reply-To: <20130211115917.GA5786@straylight.m.ringlet.net> References: <20130211120438.730ce5d3@X220.ovitrap.com> <20130211094557.GB5801@straylight.m.ringlet.net> <20130211182757.475efca2@X220.ovitrap.com> <20130211115917.GA5786@straylight.m.ringlet.net>
index | next in thread | previous in thread | raw e-mail
Hi,
On Mon, 11 Feb 2013 13:59:17 +0200
Peter Pentchev <roam@ringlet.net> wrote:
> On Mon, Feb 11, 2013 at 06:27:57PM +0700, Erich Dollansky wrote:
> >
> > >
> > > if (WIFEXITED(code)) {
> > > printf("The program exited with code %d\n",
> > > WEXITSTATUS(code));
> >
> > So, this is what I need.
>
> Actually you need the whole set of tests, not just the WIFEXITED case,
> since the program you've ran through system() may have been killed by
> a signal or something.
>
I am aware of this. This is what I need to get the results in case of a
normal program termination.
> Glad to have been of assistance!
Yes, made my life much easier.
Erich
help
Want to link to this message? Use this
URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20130211193430.2a7ef6eb>
