From: vlc <just.another.spam.account@googlemail.com>
Subject: Re: Atomic file creation
Date: Mon, 4 Jan 2010 06:45:41 -0800 (PST)
Date: 2010-01-04T06:45:41-08:00 [thread overview]
Message-ID: <9d15c089-a738-47ec-9c48-59a82f560c08@c34g2000yqn.googlegroups.com> (raw)
In-Reply-To: 4b41fa5f$0$7620$9b4e6d93@newsspool1.arcor-online.net
On Jan 4, 3:25 pm, Georg Bauhaus <rm.dash-bauh...@futureapps.de>
wrote:
> A multitasking program can use a protected object
> for this. Have all tasks perform I/O if and only if
> it is their turn as decided by the queuing control of
> the protected object.
The problem is that this file can also be created by other processes,
neither written by me nor in Ada. I doubt that I can convince an
application that I only have as a binary to respect something like
Ada's protected objects ...
> Strictly speaking, O_EXCL is not C, but it is provided by Unix's
> open(2) call. fopen(3), which is C, does not offer exclusive access
> IIRC.
That's right. I slowly mix up C with Unix.
> The Form string parameter of your Ada implementation might
> provide sharing control. The docs will then explain how a
> Form value affects files opened by many tasks; possibly even
> explain whether the form strings have an effect on using the
> external file in other programs.
Gnat only supports the SHARED and WCEM form strings, and if I
understand the documentation correctly, they have nothing to do with
exclusive open.
Thanks a lot!
next prev parent reply other threads:[~2010-01-04 14:45 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-01-04 13:40 Atomic file creation vlc
2010-01-04 14:24 ` vlc
2010-01-04 15:52 ` Jean-Pierre Rosen
2010-01-04 16:45 ` vlc
2010-01-04 17:12 ` Jean-Pierre Rosen
2010-01-04 22:38 ` Ludovic Brenta
2010-01-04 23:00 ` Dmitry A. Kazakov
2010-01-05 9:15 ` Jacob Sparre Andersen
2010-01-05 4:16 ` Stephen Leake
2010-01-05 14:48 ` vlc
2010-01-09 15:23 ` Stephen Leake
2010-01-04 14:25 ` Georg Bauhaus
2010-01-04 14:45 ` vlc [this message]
2010-01-04 14:49 ` Jacob Sparre Andersen
2010-01-04 15:07 ` vlc
2010-01-04 17:14 ` Jacob Sparre Andersen
2010-01-05 14:43 ` vlc
2010-01-06 2:28 ` Brad Moore
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox