comp.lang.ada
 help / color / mirror / Atom feed
From: "Randy Brukardt" <randy@rrsoftware.com>
Subject: Re: Exclusive file access
Date: Tue, 1 Sep 2015 15:48:23 -0500
Date: 2015-09-01T15:48:23-05:00	[thread overview]
Message-ID: <ms52uo$isd$1@loke.gir.dk> (raw)
In-Reply-To: 1441124612.29807.21.camel@obry.net

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 1627 bytes --]

"Pascal Obry" <pascal@obry.net> wrote in message 
news:1441124612.29807.21.camel@obry.net...
Le lundi 31 août 2015 à 18:20 -0500, Randy Brukardt a écrit :
>> My recollection is that getting Windows to do this requires opening files
>> with a particular non-default flag. Probably GNAT does not do that 
>> (whether
>> that is a bug or a feature is not for me to say).
>
>If my recollection is correct this is undefined by the language, so it
>can't be a bug.

It can be a bug if GNAT intended to make the Windows sharing flags available 
via a Form parameter, and just got it wrong somehow. It might be a feature 
if GNAT's authors were trying to make Windows look like Linux (a serious 
mistake IMHO, but as you say a legitimate choice vis-a-vis the RM).

I would have expected the former since AdaCore doesn't usually make easy 
things impossible for their customers. They claim (and it is backed up by 
practice) to be customer-centric. I'd expect that this capability would be 
available if some GNAT Pro customer had reported the problem, so perhaps it 
is not as important as it seems.

My personal experience is that I use the sharing flags a lot. For instance, 
for loggers, I usually open the files allowing read sharing (but not write 
sharing) so that I can read the log file while the service is running. 
(Exclusive access is exactly that, meaning that you can't even read the log 
file while it is open, and that can be pain for long-running programs.) For 
most other sorts of files, exclusive access is best. The Unix strategy of 
allowing anything is obnoxious.

                                   Randy.






  reply	other threads:[~2015-09-01 20:48 UTC|newest]

Thread overview: 52+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-08-27 13:52 Exclusive file access ahlan
2015-08-27 14:27 ` gautier_niouzes
2015-08-31 23:20   ` Randy Brukardt
2015-09-01 16:23     ` Pascal Obry
2015-09-01 20:48       ` Randy Brukardt [this message]
2015-08-27 14:42 ` Björn Lundin
2015-08-27 14:48 ` G.B.
2015-08-27 15:08   ` Björn Lundin
2015-08-27 18:38     ` tmoran
2015-08-27 23:16     ` Georg Bauhaus
2015-08-27 23:29       ` Pascal Obry
2015-08-28  7:25         ` Georg Bauhaus
2015-08-27 15:15   ` ahlan
2015-08-27 18:29     ` Jeffrey R. Carter
2015-08-28  5:41 ` ahlan
2015-08-28  7:10   ` Georg Bauhaus
2015-08-28 17:40 ` ahlan
2015-08-28 19:49   ` Anh Vo
2015-08-28 21:06     ` Simon Wright
2015-08-28 21:38       ` Jeffrey R. Carter
2015-08-29  7:05   ` Dmitry A. Kazakov
2015-08-29  8:31     ` Pascal Obry
2015-08-29 12:02       ` Dmitry A. Kazakov
2015-08-30 11:35         ` Florian Weimer
2015-08-30 12:44           ` Dmitry A. Kazakov
2015-08-30 19:37             ` Florian Weimer
2015-08-31  7:22               ` Dmitry A. Kazakov
2015-08-31 21:12                 ` Florian Weimer
2015-09-01  7:26                   ` Dmitry A. Kazakov
2015-09-07 18:27                     ` Florian Weimer
2015-09-07 19:06                       ` Dmitry A. Kazakov
2015-09-11 16:54                         ` Florian Weimer
2015-08-31 23:34             ` Randy Brukardt
2015-09-01  7:33               ` Dmitry A. Kazakov
2015-08-29 16:07     ` gautier_niouzes
2015-08-29 17:12       ` Dmitry A. Kazakov
2015-09-01 12:37 ` brbarkstrom
2015-09-01 14:05 ` ahlan
2015-09-01 15:13   ` Simon Wright
2015-09-01 20:36     ` Randy Brukardt
2015-09-01 15:17   ` Jacob Sparre Andersen
2015-09-01 20:37     ` Randy Brukardt
2015-09-01 16:05   ` G.B.
2015-09-01 20:02   ` brbarkstrom
2015-09-01 21:17     ` Simon Wright
2015-09-05 15:52       ` Björn Lundin
2015-09-01 20:31   ` Randy Brukardt
2015-09-01 15:31 ` ahlan
2015-09-05 15:56   ` Björn Lundin
2015-09-06 17:38     ` brbarkstrom
2015-09-06 19:52       ` Björn Lundin
2015-09-07 15:18         ` brbarkstrom
replies disabled

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