[issue815646] thread unsafe file objects cause crash
Gregory P. Smith
report at bugs.python.org
Sun Apr 6 08:25:11 CEST 2008
Gregory P. Smith <greg at krypto.org> added the comment:
I've attached my patch that I want to commit. The main change from
filethread4 is some cleanup in file_test to make it run a lot faster and
add verbose mode output to indicate how well it is actually testing the
problem (counting the times that close raises IOError).
One concern holding up my commit:
Will this test pass on windows? It is opening and closing the same file
in 'w+' mode from multiple threads of the same process at once.
Can someone with a windows dev environment please apply this patch and
test it. If it dislikes the above file behavior, can you propose a fix
for it (set windows file non-exclusive flags or whatever you're supposed
to do... the worse alternative would be to use a new filename on each
open but that could cause a nightmare of thousands of new files being
created by the test which then have to be cleaned up)?
thanks,
-gps
Added file: http://bugs.python.org/file9958/filethread4-gps01.patch
____________________________________
Tracker <report at bugs.python.org>
<http://bugs.python.org/issue815646>
____________________________________
More information about the Python-bugs-list
mailing list