Path: utzoo!utgpu!news-server.csri.toronto.edu!bonnie.concordia.ca!thunder.mcrcim.mcgill.edu!snorkelwacker.mit.edu!usc!zaphod.mps.ohio-state.edu!rpi!uupsi!sunic!news.funet.fi!ra!rosenber From: rosenber@ra.abo.fi (Robin Rosenberg INF) Newsgroups: comp.sys.amiga.programmer Subject: Re: HELP with Independant Children Processes Message-ID: Date: 8 Feb 91 05:08:28 GMT References: <1991Feb7.001246.5257@maytag.waterloo.edu> Sender: rosenber@ra.abo.fi Organization: Abo Akademi University, Finland Lines: 16 In-reply-to: giguere@csg.uwaterloo.ca's message of 7 Feb 91 00:12:46 GMT In article <1991Feb7.001246.5257@maytag.waterloo.edu> giguere@csg.uwaterloo.ca (Eric Giguere) writes: >One thing I'm not sure about, though: does the parent have to remain >running to eventually do an UnloadSeg() on the child process? The AmigaDOS >docs aren't too clear on that one... I would like to know. You obviously cannot UnloadSeg() yourself. However you can make a copy of the entry/exit code, hang the copy onto the task's tc_MemEntry list. Then you give the copied code to CreateProc(). When the process finishes control returns to the copied code which UnloadSeg()s and exists. The memory occupied by the copied code is freed by exec when the process terminates. This is essentially what the SAS C cback startup module does. Take a look at it. -------- Robin