This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author aclover
Recipients aclover
Date 2010-10-21.00:44:34
SpamBayes Score 4.5891668e-10
Marked as misclassified No
Message-id <1287621877.59.0.625449070173.issue10162@psf.upfronthosting.co.za>
In-reply-to
Content
It is relatively common to have keys in the HKEY_CLASSES_ROOT MIME database that are not readable to all users, typically written by third-party applications. (My WinXP test box has a dozen, for apps like Flash, Silverlight and Java.)

Currently, initialising mimetypes causes Python to try to read them all, and if the user running Python doesn't have permission to read a key (in particular, if the user is a low-privilege daemon user such as IUSR_...), the script that caused mimetypes to be called will error out.

This patch moves the try-block around the call to OpenKey as well as QueryValueEx, allowing the key to be skipped if unreadable.
History
Date User Action Args
2010-10-21 00:44:37acloversetrecipients: + aclover
2010-10-21 00:44:37acloversetmessageid: <1287621877.59.0.625449070173.issue10162@psf.upfronthosting.co.za>
2010-10-21 00:44:35acloverlinkissue10162 messages
2010-10-21 00:44:34aclovercreate