消息 [86747]
In Python 2.6.2, the fix for the issue 5401 changed the way the
mimetypes module is initialized.
But now the initialization is not thread-safe : a thread can set
``inited`` to ``True`` and then be preempted before to overwrite the
functions guess_type(), guess_extension() ...
With such a partial initialization, the next thread will raise an
excessive recursion exception when calling one of this functions.
A fix could be to wrap ``mimetypes.init()`` with a thread lock. |
|
| 日期 |
用户 |
动作 |
参数 |
| 2009-04-28 14:51:57 | apoirier | 修改 | recipients:
+ apoirier, benjamin.peterson |
| 2009-04-28 14:51:57 | apoirier | 修改 | messageid: <1240930317.8.0.75459471021.issue5868@psf.upfronthosting.co.za> |
| 2009-04-28 14:51:56 | apoirier | 链接 | issue5868 messages |
| 2009-04-28 14:51:54 | apoirier | 创建 | |
|