home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!spool.mu.edu!olivea!charnel!sifon!thunder.mcrcim.mcgill.edu!mouse
- From: mouse@thunder.mcrcim.mcgill.edu (der Mouse)
- Newsgroups: comp.lang.c
- Subject: Re: stderr: Question
- Keywords: fprintf stderr
- Message-ID: <1992Dec23.172219.11906@thunder.mcrcim.mcgill.edu>
- Date: 23 Dec 92 17:22:19 GMT
- References: <1992Dec21.134608.16856@ifi.unizh.ch>
- Organization: McGill Research Centre for Intelligent Machines
- Lines: 19
-
- In article <1992Dec21.134608.16856@ifi.unizh.ch>, caliaro@avalon.physik.unizh.ch (Aurelio Caliaro) writes:
-
- > I would like to redirect all output made by "fprintf(stderr, ...)" to
- > a procedure. Is that possible without changing the source everytime
- > that stderr comes?
-
- No, and not really even then. Standard stdio has little or no support
- for coroutine streams. (My stdio does, in the form of fopenfxn(), and
- it's useful. But it's a long way from standard, and isn't even
- redistributable (yet).)
-
- Depending on precisely what effect you're trying to achieve, you may be
- able to get it by forking a process to which you then connect stderr,
- and having it do whatever you want.
-
- der Mouse
-
- mouse@larry.mcrcim.mcgill.edu
-