[issue815646] thread unsafe file objects cause crash

Antoine Pitrou report at bugs.python.org
Sat Mar 29 01:30:36 CET 2008


Antoine Pitrou <pitrou at free.fr> added the comment:

Some good news: I've found a way to continue with my approach and make
it working. The close() method now raises an appropriate IOError when
another method is being called from another thread. Attaching a patch,
which protects a bunch of file object methods (together with tests). 

Now the bad news: the protection logic in fileobject.c is, hmm, a bit
contrived (and I'm not even sure it's 100% correct). If someone wants to
read it and put his veto before I go further...

Added file: http://bugs.python.org/file9884/filethread2.patch

____________________________________
Tracker <report at bugs.python.org>
<http://bugs.python.org/issue815646>
____________________________________


More information about the Python-bugs-list mailing list