]> granicus.if.org Git - python/commit
Make file objects as thread safe as the underlying libc FILE* implementation.
authorGregory P. Smith <greg@mad-scientist.com>
Sun, 6 Apr 2008 23:11:17 +0000 (23:11 +0000)
committerGregory P. Smith <greg@mad-scientist.com>
Sun, 6 Apr 2008 23:11:17 +0000 (23:11 +0000)
commitaa63d0d4af3db832b390ac74517af5eb799540e5
tree86818f84f404fef73ee3f56eb0945334b4d52cb8
parentee76777846124bb5b7e08feb488d5bab949c76a5
Make file objects as thread safe as the underlying libc FILE* implementation.
close() will now raise an IOError if any operations on the file object
are currently in progress in other threads.

Most code was written by Antoine Pitrou (pitrou).  Additional testing,
documentation and test suite cleanup done by me (gregory.p.smith).

Fixes issue 815646 and 595601 (as well as many other bugs and
references to this problem dating back to the dawn of Python).
Doc/c-api/file.rst
Include/fileobject.h
Lib/test/test_file.py
Misc/NEWS
Objects/fileobject.c