Path: utzoo!attcan!uunet!cs.utexas.edu!swrinde!zaphod.mps.ohio-state.edu!rpi!bu.edu!orc!inews!iwarp.intel.com!psueea!eecs!griffith From: griffith@eecs.cs.pdx.edu (Michael Griffith) Newsgroups: comp.sys.amiga.tech Subject: Re: Writing programs for background tasks Message-ID: <3257@psueea.UUCP> Date: 20 Aug 90 08:05:29 GMT References: <3066@orbit.cts.com> Sender: news@psueea.UUCP Reply-To: griffith@eecs.UUCP (Michael Griffith) Organization: Portland State University, Portland, OR Lines: 17 I have absolutely no idea from your original article what language you are programming in. But, if you are using Manx Aztec C (my version is 3.6a), a feature was provided to supply this capability. First, you declare four long integers at the beginning of your program: long _stack=; /* size of stack to use, 0 to use current CLI value */ long _priority=; /* priority to run at (normally 0) */ long _BackGroundIO=; /* nonzero if output to CLI console is needed */ char *_procname=""; /* string containing name of the new process */ You then link detach.o to your program, which takes care of detaching your program from it's initial CLI, optionally running it in the background. Michael Griffith griffith@eecs.ee.pdx.edu uunet!tektronix!psueea!eecs!griffith "Say, 'I will not program in Pascal.'"