MESSAGE
DATE | 2011-06-26 |
FROM | Ruben Safir
|
SUBJECT | Subject: [NYLXS - HANGOUT] (fwd) Re: C++ file locking
|
-- forwarded message -- Path: reader1.panix.com!panix!news.linkpendium.com!news.linkpendium.com!feeder.erje.net!news-transit.tcx.org.uk!nntp-feed.chiark.greenend.org.uk!ewrotcd!nntp.anjou.terraraq.org.uk!.POSTED!not-for-mail From: Richard Kettlewell Newsgroups: comp.os.linux.development.apps Subject: Re: C++ file locking Date: Fri, 10 Jun 2011 09:31:36 +0100 Organization: Anjou Lines: 20 Message-ID: <87y61akryv.fsf-at-araminta.anjou.terraraq.org.uk> References: <16265495-eb93-4e2e-a46c-f16bb6b19d9e-at-b1g2000yql.googlegroups.com> NNTP-Posting-Host: 2001:470:1f09:11ed::12 Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: araminta.anjou.terraraq.org.uk 1307694696 346 2001:470:1f09:11ed::12 (10 Jun 2011 08:31:36 GMT) X-Complaints-To: usenet-at-sfere.greenend.org.uk NNTP-Posting-Date: Fri, 10 Jun 2011 08:31:36 +0000 (UTC) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.2 (gnu/linux) X-Face: h[Hh-7npe< F<\{jehn7.KrO{!7=:(-at-J~]<.[{>v9!1Z&W?r\c.!4DXH5PWpga"ha +r0NzP?vnz:e/knOY)PI- X-Boydie: NO Cancel-Lock: sha1:wyzr/BbTDt/8rq2BUvkTx4QVeT8= Xref: panix comp.os.linux.development.apps:166502
Ruben Safir writes: > Lukas 'Erdk' Redynk wrote:
>> You could try this: >> http://linux.die.net/man/3/lockf >> or >> http://www.manpagez.com/man/2/fcntl/ - especially F_GETLK and F_SETLK > > Yes but these both require you to get a file descriptor from the open > call, effectively doing an end run around ios_base.
Yes.
> Is there no purely C++ mechanism of do this, or aquiring the file > descriptor from iosteams?
http://gcc.gnu.org/onlinedocs/libstdc++/manual/ext_io.html
-- http://www.greenend.org.uk/rjk/ -- end of forwarded message --
|
|