home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.sys.atari.st.tech
- Path: sparky!uunet!utcsri!torn!newshost.uwo.ca!uwovax.uwo.ca!7103_2622
- From: 7103_2622@uwovax.uwo.ca (Eric Smith)
- Subject: Re: LASER C PRINTING
- Organization: University of Western Ont, London
- Date: Fri, 4 Sep 1992 21:57:35 GMT
- Message-ID: <1992Sep4.175735.1@uwovax.uwo.ca>
- References: <1992Sep4.145336.4676@news.csuohio.edu>
- Sender: news@julian.uwo.ca (USENET News System)
- Nntp-Posting-Host: hydra.uwo.ca
- Lines: 26
-
- In article <1992Sep4.145336.4676@news.csuohio.edu>, max@neumann.cba.csuohio.edu (Max Polk) writes:
- [ description of Laser C stdio setup deleted ]
-
- > Even if you can manage to Fdup the console output and change the
- > association of stderr to it, programs executed with this in place won't
- > care about what you did, because only file descriptors 0 and 1 have
- > significance.
-
- A clarification:
-
- That's true for Laser C (with the default Laser C library) but not necessarily
- for other compilers/libraries. For example, the MiNT library and gcc library
- use handle 2 for stderr; they do this by checking to see if handle 2 is
- pointing at a terminal of some kind (by default this is true, since GEMDOS
- sets handle 2 to point at the serial port). If it is, then it is redirected
- to point at the console. If it is not (if someone has pointed handle 2
- at a file, for example) it's left alone.
-
- For this reason, programs should not assume anything about handle 2 (e.g.
- it's better not to assume that it's pointing to the serial port). If
- you want to open the serial port, use the file name "AUX:".
- --
- Eric R. Smith email:
- Dept. of Mathematics eric.smith@uwo.ca
- University of Western Ontario
-
-