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=-1.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,ed7075f5ab49c273 X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2004-03-15 21:28:55 PST Path: archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-01!sn-post-01!supernews.com!corp.supernews.com!not-for-mail From: "Randy Brukardt" Newsgroups: comp.lang.ada Subject: Re: Files opened for exclusive read Date: Mon, 15 Mar 2004 23:28:33 -0600 Organization: Posted via Supernews, http://www.supernews.com Message-ID: <105d44ndehghj94@corp.supernews.com> References: <686be06c.0403050513.632eb334@posting.google.com> X-Priority: 3 X-MSMail-Priority: Normal X-Newsreader: Microsoft Outlook Express 5.50.4807.1700 X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4910.0300 X-Complaints-To: abuse@supernews.com Xref: archiver1.google.com comp.lang.ada:6336 Date: 2004-03-15T23:28:33-06:00 List-Id: "Dan Allex" wrote in message news:UIednfmQiM5acdbd4p2dnA@adelphia.com... > Apparently, this is a short comming of Object Ada running on NT. > Appreciate all the responses. I'm trying to convince the powers that be > to migrate to GNAT. > > Daniel Allex wrote: > > When Ada opens a file, the only option is for exclusive use. This > > causes a problem when multiple executables may be reading at the same > > time. Any suggestions? (I know this is late; I'm just back from a week off...) When the file is opened in Windows, it is necessary to pass the appropriate sharing bits. By default, files are opened for exclusive access in Windows. I think most Ada run-time systems just do the default by default. But good Windows compilers support some sort of Form parameter to set the sharing mode. Certainly Janus/Ada does that, and I'm pretty sure we got the idea from the Aonix Ada 83 compilers. So I'd be quite surprised if ObjectAda doesn't have a way to do it. Note that this has nothing to do with Ada, so the technique for doing it is likely to be completely different on each compiler. I'd suggest contacting Aonix's support people with your question (presuming you can't find any discussion of it in their documentation). (I'm not convinced that the GNAT support really will solve your problem, although there probably is some way to get the handle opened directly by Windows and then used as an Ada file.) Randy.