On 16Jul2011 10:37, Josh English <joshua.r.engl...@gmail.com> wrote:
| You use a directory as lock mechanism. I think I get how that works.
| When you're done manipulating the file, do you just remove the director?

Yes. The advantages of a directory are twofold: you can't mkdir() twice
while you can usually open the same file for write more than once (hence
the umask 0777 thing, to prevent that); secondly you can put stuff in it
though that makes removing the directory more work when you're done with
it.

Cheers,
-- 
Cameron Simpson <c...@zip.com.au> DoD#743
http://www.cskk.ezoshosting.com/cs/

THE LOST WORLD is based on (so loosely as to re-define "based on" as
"with the same title as") Michael Crichton's sequel novel, which
introduced us to a second island where dinosaurs were being genetically
engineered.     - Scott Renshaw on _Jurassic_Park_'s sequel
-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to