home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #20 / NN_1992_20.iso / spool / comp / lang / perl / 5743 < prev    next >
Encoding:
Internet Message Format  |  1992-09-07  |  717 b 

  1. Path: sparky!uunet!munnari.oz.au!spool.mu.edu!darwin.sura.net!wupost!usc!news!netlabs!lwall
  2. From: lwall@netlabs.com (Larry Wall)
  3. Newsgroups: comp.lang.perl
  4. Subject: Re: reopening STDOUT as another stream
  5. Message-ID: <1992Sep5.071243.8404@netlabs.com>
  6. Date: 5 Sep 92 07:12:43 GMT
  7. References: <lafrc7INN84@jethro.Corp.Sun.COM>
  8. Sender: news@netlabs.com
  9. Organization: NetLabs, Inc.
  10. Lines: 11
  11. Nntp-Posting-Host: scalpel.netlabs.com
  12.  
  13. In article <lafrc7INN84@jethro.Corp.Sun.COM> tmhoff@oogoody.Corp.Sun.COM writes:
  14. : I can't quite figure out how to freopen STDOUT as another
  15. : stream. Any suggestions?
  16.  
  17. If you aren't running an ancient version, ordinary open should work
  18. fine for that:
  19.  
  20.     open(STDOUT, "| lpr")
  21.  
  22. Larry
  23.