comp.lang.ada
 help / color / mirror / Atom feed
From: Adrien Plisson <aplisson-news@stochastique.net>
Subject: Re: Finalization of a record containing a task
Date: Thu, 17 Feb 2005 09:24:16 +0100
Date: 2005-02-17T09:24:16+01:00	[thread overview]
Message-ID: <421454b0$0$9136$ba620e4c@news.skynet.be> (raw)
In-Reply-To: <wccu0ocxil7.fsf@shell01.TheWorld.com>

Robert A Duff wrote:
> Adrien Plisson <aplisson-news@stochastique.net> writes:
>>alternately, since T_ADT is Limited_Controlled, you may abort the inner
>>task in its Finalize (!! baaad !!)
> 
> 
> But the problem is that the program hangs, waiting for termination of
> the task, *before* it calls the Finalize that does the abort
> (or calls the Stop entry, in the original example).

euh... yes, you are right. i do remember now that when i did that, i 
was using an access to the task type.

anyway, it is a very bad idea since aborting the task may have a side 
effect: you don't know what was going on at the time you abort the 
task, so the state of the data accessed by the task is undefined.

-- 
rien



  reply	other threads:[~2005-02-17  8:24 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-02-16 20:35 Finalization of a record containing a task Bj?rn
2005-02-16 20:49 ` Stephen Leake
2005-02-16 21:20   ` Adrien Plisson
2005-02-16 22:09     ` Robert A Duff
2005-02-17  8:24       ` Adrien Plisson [this message]
2005-02-18  0:17         ` Robert A Duff
2005-02-17  9:13     ` Dmitry A. Kazakov
2005-02-18  0:13       ` Robert A Duff
2005-02-18  2:34         ` Randy Brukardt
2005-02-18 11:27         ` Dmitry A. Kazakov
2005-02-16 22:08   ` Robert A Duff
2005-02-21 13:20     ` Craig Carey
2005-02-21 21:41       ` Robert A Duff
2005-02-22  0:15         ` Randy Brukardt
2005-02-17 17:50   ` Bj?rn
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox