Path: utzoo!utgpu!utfyzx!oscvax!flynn From: flynn@oscvax.UUCP (Flynn D. Fishman) Newsgroups: comp.sys.amiga Subject: Re: Spawning tasks which draw . . . Message-ID: <554@oscvax.UUCP> Date: Fri, 18-Dec-87 16:35:27 EST References: <8712081929.AA17657@cory.Berkeley.EDU> <4696@well.UUCP> Reply-To: flynn@oscvax.UUCP (Flynn D. Fishman) Organization: Ontario Science Centre, Toronto Lines: 56 Keywords: Why Forbid()? In article <4696@well.UUCP> ewhac@well.UUCP (Leo 'Bols Ewhac' Schwab) writes: > A more general (and better, in my opinion) way to go about this is >as follows: >------- > PARENT CHILD > Parent sends kill signal to > child. > Parent waits for reply. > Child receives kill signal. > Child cleans up anything it > allocated. > Child Forbid()s. ^^^^^^^^^^^^^^^^^ > Child replies signal. > Child waits for Godot (Wait (0L)). > Parent receives reply. > Parent RemTask()s child. >------- My question is this, why should the Child Forbid(), and who does the Permit() is that Automatic. I do not see any reason why the Child should Forbid() since the parent is locked waiting for a reply anyways. Also. I am using Manx 3.4a, and have my Task in the same file as the parent. What I do is have my task check to see if he/she got a message directing him/her to die (exit nicely). When he/she gets the message (s)he clears all the memory (s)he allocated, etc. and just falls of the end of the world, either by letting her code run out or via return; I think this has its advantages in that a task can be killed by some other process if neccessary. As well since I am a Multitasking Novice, (ok novice), is RemTask neccessary? And what exactly does it do. On another note (c minor) if I spawn my task as indicated before, (using only local variables) and the mainline goes bye bye, does my system guru and start spouting smoke or does the memory used by my task still exist? (I vote for the guru but I have not had time to check and see) p.s. I just got a 1084, and do not seem to have any problems with it, In fact I like the pictures 10+ times better that the 2002 at work (but the 2002 seems to be worse than normal) -- Please ignore any spelling, or grammarical errors, I am using a really lousy keyboard. (The fact that I do not speak to goodlooking english does not help the matter much either) _Flynn D. Fishman, Esquire (Ontario Science Centre) ...{watmath,ihnp4,decvax,cbosgd}!utgpu!oscvax!flynn Soon to be (as I am going back to school) ...{watmath,ihnp4,decvax,cbosgd}!watcgl!fdfishman