Path: utzoo!attcan!uunet!husc6!bloom-beacon!mit-eddie!ll-xn!ames!ubvax!ardent!rap From: rap@ardent.UUCP (Rob Peck) Newsgroups: comp.sys.amiga Subject: Re: Filehandles and Execute() Keywords: execute Message-ID: <715@ardent.UUCP> Date: 14 Nov 88 19:06:17 GMT References: <4997@garfield.MUN.EDU> Distribution: na Organization: Dana Computer, Inc., Sunnyvale, CA Lines: 21 In article <4997@garfield.MUN.EDU>, john13@garfield.MUN.EDU (John Russell) writes: > 1. Can I use the same MODE_NEWFILE handle for both input and output handles? As I recall, yes. struct FileHandle *nilfh, *Open(); /* (I dont have my manuals handy) */ nilfh = Open("nil:",MODE_NEWFILE); success = Execute("foo",nilfh,nilfh); Close(nilfh); > 2. Will Execute close the file handles when it finishes? NO. It USES them, and has no idea where they came from. In creating the original version of RUNBACKGROUND, I did an extensive analysis of what happens when you substitute one or both of the file handles in Execute instead of using 0,0. I will try to locate that analysis and post it. Rob Peck