From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-0.3 required=5.0 tests=BAYES_00,FORGED_YAHOO_RCVD, FREEMAIL_FROM autolearn=no autolearn_force=no version=3.4.4 X-Google-Thread: a07f3367d7,23ffa52608fbb144 X-Google-Attributes: gida07f3367d7,public,usenet X-Google-NewGroupId: yes X-Google-Language: ENGLISH,ASCII-7-bit Received: by 10.205.134.138 with SMTP id ic10mr1755153bkc.8.1337432017065; Sat, 19 May 2012 05:53:37 -0700 (PDT) Path: e27ni16611bkw.0!nntp.google.com!news1.google.com!npeer02.iad.highwinds-media.com!news.highwinds-media.com!feed-me.highwinds-media.com!post02.iad.highwinds-media.com!KNOLOGY.NET-a2kHrUvQQWlmc!not-for-mail From: Tim McGuire Newsgroups: comp.lang.ada Subject: Re: Problem with Delay Alternative in Finalization Date: Sat, 19 May 2012 07:51:59 -0500 Message-ID: <195fr7578nlfuegpdm70u1lk51lrg1pk7d@4ax.com> References: <6v0er7d545kvs3pr7aqe1dnrlq4mg5ldhg@4ax.com> X-Newsreader: Forte Agent 6.00/32.1186 trialware MIME-Version: 1.0 X-Complaints-To: abuse@usenetserver.com Organization: UseNetServer.com X-Trace: c43184fb798e8bd8f493d04640 X-Received-Bytes: 1933 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Date: 2012-05-19T07:51:59-05:00 List-Id: I know about the task identification, the original code is a lot more complex than the simple example I provided. In the original code, Initialize actually calls another function which has the select with the delay alternative, since sometimes the token functionality is used directly rather than through finalization. I had notice the direct use of the token did function properly, it was only when used in finalization that it wasn't working. The code works fine under Solaris with the Rational compiler, so is it a GNAT issue? Or should it have not worked to start with? And why doesn't the program crash on the Program_Error, rather than just hang indefinitely? On Sat, 19 May 2012 08:12:55 +0200, "Dmitry A. Kazakov" wrote: >On Fri, 18 May 2012 21:30:31 -0500, Tim McGuire wrote: > >> I am running in to a problem where a delay alternive used when in >> finalization doesn't seem to be working properly. >> The delay part never seems to happen. > >It is Program_Error to propagate an exception from Initialize, which is >what I think happens when you raise Lock_Timeout_Exception. > >BTW, you can use task identification in order to allow reentrant locks.