Path: utzoo!utgpu!news-server.csri.toronto.edu!rutgers!ucsd!ucbvax!agate!shelby!neon!Gang-of-Four!dkeisen From: dkeisen@Gang-of-Four.Stanford.EDU (Dave Eisen) Newsgroups: comp.lang.c Subject: Re: Controlling stdin and stdouts of other executables Message-ID: <1990May2.063730.5867@Neon.Stanford.EDU> Date: 2 May 90 06:37:30 GMT References: <10765@shlump.nac.dec.com> <3967@hcx1.SSD.CSD.HARRIS.COM> <6418@star.cs.vu.nl> Sender: news@Neon.Stanford.EDU (USENET News System) Organization: Sequoia Peripherals Lines: 18 >)... >)If all you want to do is IGNORE the error and standard output from your >)command, then the following should work: > >You don't want to close the standard streams, you want to connect them >to /dev/null, quite a difference! > and this is most easily done using the shell's usual redirection operators: system ("command > /dev/null 2>&1"); -- Dave Eisen Home: (415) 323-9757 dkeisen@Gang-of-Four.Stanford.EDU Office: (415) 967-5644 "I drive a brand new BMW and I wear an unusually large shoe..."