Help: using msvcrt for file locking

Sheila King sheila at spamcop.net
Sun Aug 26 11:09:14 EDT 2001


On Sun, 26 Aug 2001 11:44:17 GMT, bokr at accessone.com (Bengt Richter)
wrote in comp.lang.python in article
<3b88ddd1.500819830 at wa.news.verio.net>:

:http://starship.python.net/crew/jjkunce/python/ntposixfile.py
:
:might be useful?
:Note from my other post: Microsoft example code for _locking uses
:_sopen rather than fopen (or _open). The s in _sopen is for shared
:file access, so I wonder if python's builtin open is affected, since
:it uses fopen.
:
:The ntposixfile.py seems to go to __builtin__.open() as well, though,
:so if _sopen does something different and required, the same problem
:should appear. Hard to believe there wouldn't be more noise on google
:about it though, if _locking didn't work with fopen, unless people
:just quietly give up and go on to the win32 api...

I did download and try that code a couple of days ago. (Note that it
says, it hasn't really been tested thoroughly.)

Anyhow, when I tried to run the master/slave __main__ code in two
separate DOS console windows to test it, I got the "Permission denied"
errors using that module.

--
Sheila King
http://www.thinkspot.net/sheila/
http://www.k12groups.org/




More information about the Python-list mailing list