Re: windows bug: filewritable() returns 0 if we use it on the current script being read

2010-11-07 Fir de Conversatie Philippe Vaucher
So, who has to authority on this? Should we allow multiple writers to a file? Should we allow writers on currently read file? If no how drastics are the changes to be made to the linux api? Philippe -- You received this message from the "vim_dev" maillist. Do not top-post! Type your reply below

Re: windows bug: filewritable() returns 0 if we use it on the current script being read

2010-11-04 Fir de Conversatie Philippe Vaucher
> > Assuming you don't want permissive sharing when doing actual > > I/O (I argue above that you don't), I question the value of > > changing mch_access() in the proposed way.  The point of > > mch_access() is to give you a predictor of what types of > > access will likely work.  If the access chec

RE: windows bug: filewritable() returns 0 if we use it on the current script being read

2010-11-03 Fir de Conversatie John Beckett
Craig Barkhouse wrote: > Assuming you don't want permissive sharing when doing actual > I/O (I argue above that you don't), I question the value of > changing mch_access() in the proposed way. The point of > mch_access() is to give you a predictor of what types of > access will likely work. If th

RE: windows bug: filewritable() returns 0 if we use it on the current script being read

2010-11-03 Fir de Conversatie Craig Barkhouse
Phillippe Vaucher wrote: > > I'm pretty sure you nomally WANT to lock a file from being written, > > while you are executing its contents as a script. It sounds like this > > is what is happening. Is there some reason you want to write the file > > while executing it? > > This bug arised from a s

Re: windows bug: filewritable() returns 0 if we use it on the current script being read

2010-11-03 Fir de Conversatie Philippe Vaucher
> I'm pretty sure you nomally WANT to lock a file from being written, > while you are executing its contents as a script. It sounds like this > is what is happening. Is there some reason you want to write the file > while executing it? This bug arised from a script that checked wether itself was w

Re: windows bug: filewritable() returns 0 if we use it on the current script being read

2010-11-03 Fir de Conversatie Philippe Vaucher
> It makes sense, but we must make sure this does not cause any trouble. > Does it work on all Windows versions? I don't know how I can make sure this doens't make any trouble... but if your question is if CreateFile()'s dwShareMode flag is supported on all flavors of windows I think the answer is

Re: windows bug: filewritable() returns 0 if we use it on the current script being read

2010-11-03 Fir de Conversatie Ben Fritz
On Nov 2, 7:21 am, Philippe Vaucher wrote: > Hello, > > I think I've found a bug for vim under windows. > > Basically if inside a vim script you do > "filewritable(expand(''))" it returns 0 even if the file is > writable. > > I read the source and basically it boils down to that the dwShareMode

Re: windows bug: filewritable() returns 0 if we use it on the current script being read

2010-11-03 Fir de Conversatie Bram Moolenaar
Philippe Vaucher wrote: > I think I've found a bug for vim under windows. > > Basically if inside a vim script you do > "filewritable(expand(''))" it returns 0 even if the file is > writable. > > I read the source and basically it boils down to that the dwShareMode > param of CreateFile() is 0,

Re: windows bug: filewritable() returns 0 if we use it on the current script being read

2010-11-03 Fir de Conversatie Philippe Vaucher
Hum? Should I submit a patch? This is a bug right? -- You received this message from the "vim_dev" maillist. Do not top-post! Type your reply below the text you are replying to. For more information, visit http://www.vim.org/maillist.php