mirror of
https://github.com/python/cpython.git
synced 2025-08-04 17:08:35 +00:00
Issue #13025: mimetypes is now reading MIME types using the UTF-8 encoding,
instead of the locale encoding.
This commit is contained in:
parent
c1f32ca0ad
commit
82ac9bcdb3
4 changed files with 1464 additions and 3 deletions
|
@ -199,7 +199,7 @@ class MimeTypes:
|
|||
list of standard types, else to the list of non-standard
|
||||
types.
|
||||
"""
|
||||
with open(filename) as fp:
|
||||
with open(filename, encoding='utf-8') as fp:
|
||||
self.readfp(fp, strict)
|
||||
|
||||
def readfp(self, fp, strict=True):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue