home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #26 / NN_1992_26.iso / spool / comp / unix / programm / 5254 < prev    next >
Encoding:
Text File  |  1992-11-11  |  1.1 KB  |  29 lines

  1. Newsgroups: comp.unix.programmer
  2. Path: sparky!uunet!caen!batcomputer!theory.TC.Cornell.EDU!mdw
  3. From: mdw@theory.TC.Cornell.EDU (Matt Welsh)
  4. Subject: Re: Creating a background process from within C prog
  5. Message-ID: <1992Nov12.003035.24322@tc.cornell.edu>
  6. Sender: news@tc.cornell.edu
  7. Nntp-Posting-Host: theory.tc.cornell.edu
  8. Organization: Cornell Theory Center
  9. References: <BwsyCt.9Gx@acsu.buffalo.edu> <HUANG1.92Nov10171831@husc10.harvard.edu> <1992Nov11.032950.23086@leland.Stanford.EDU>
  10. Date: Thu, 12 Nov 1992 00:30:35 GMT
  11. Lines: 16
  12.  
  13. In article <1992Nov11.032950.23086@leland.Stanford.EDU> dkeisen@leland.Stanford.EDU (Dave Eisen) writes:
  14. >If you're going to use system, you might as well take the shell
  15. >you spawn for all it's worth and write:
  16. >
  17. >      system ("ls > /tmp/myfile &");
  18.  
  19. Um, why? The process running the system is fork()ed from the parent, which 
  20. isn't neccesarily wait()ing for the child to finish. That won't buy you
  21. much (unless I'm very confused :)). 
  22.  
  23. mdw
  24.  
  25. -- 
  26. Matt Welsh    mdw@tc.cornell.edu        +1 607 253 2737
  27. Systems Programmer, Cornell Theory Center
  28.   "She's like jelly roll, like sculpture!"
  29.