[Mono-list] File Locking

2014-09-12 Thread Edward Ned Harvey (mono)
Ack! I just realized this doesn't work: var lockFile = new FileStream("myfile.lock",FileMode.OpenOrCreate,FileAccess.ReadWrite,FileShare.None); Particularly, if more than one application attempts to get an exclusive lock on that file at the same time (FileShare.None), then both applications sim

Re: [Mono-list] File Locking

2016-02-16 Thread shrimpywu
i have the same issue. any solution? -- View this message in context: http://mono.1490590.n4.nabble.com/File-Locking-tp4663839p4667446.html Sent from the Mono - General mailing list archive at Nabble.com. ___ Mono-list maillist - Mono-list@lists.xim

Re: [Mono-list] File Locking

2016-02-17 Thread Edward Ned Harvey (mono)
> From: mono-list-boun...@lists.ximian.com [mailto:mono-list- > boun...@lists.ximian.com] On Behalf Of shrimpywu > > i have the same issue. any solution? Kinda sorta. The underlying issue is that OSX, Linux, and Windows all have different underlying file locking constructs, and then of course, t

Re: [Mono-list] File Locking

2016-02-17 Thread Andy York
Sent: Wednesday, February 17, 2016 9:46 AM To: "shrimpywu" , "mono-list@lists.ximian.com" Subject: Re: [Mono-list] File Locking > From: mono-list-boun...@lists.ximian.com [mailto:mono-list- > boun...@lists.ximian.com] On Behalf Of shrimpywu > > i have the same is

Re: [Mono-list] File Locking

2016-02-17 Thread Edward Ned Harvey (mono)
> From: mono-list-boun...@lists.ximian.com [mailto:mono-list- > boun...@lists.ximian.com] On Behalf Of Andy York > > Have you tried checking out other project in GitHub or CodePlex? I've gotten > some really good tips from reading other cross-platform code that deals with > locking files. Just a s

Re: [Mono-list] File Locking

2016-02-18 Thread Andy York
uot;mono-list@lists.ximian.com" Subject: RE: [Mono-list] File Locking > From: mono-list-boun...@lists.ximian.com [mailto:mono-list- > boun...@lists.ximian.com] On Behalf Of Andy York > > Have you tried checking out other project in GitHub or CodePlex? I've gotten >

Re: [Mono-list] File Locking

2016-02-19 Thread Edward Ned Harvey (mono)
> From: mono-list-boun...@lists.ximian.com [mailto:mono-list- > boun...@lists.ximian.com] On Behalf Of Andy York > > I have found help in the Banshee source code particularly in > Banshee.Core/Banshee.IO.SystemIO namespace.  Also FSpot has some IO > classes that may be of help try the FSpot.Core/F