summaryrefslogtreecommitdiffstats
path: root/Doc/library
diff options
context:
space:
mode:
authorVictor Stinner <victor.stinner@haypocalc.com>2010-10-09 10:34:37 (GMT)
committerVictor Stinner <victor.stinner@haypocalc.com>2010-10-09 10:34:37 (GMT)
commit62165d67a25229fee85c98cef9d1feaf109b1339 (patch)
tree77193a4f306941b520b8aa5c5eed8611c00fa1a7 /Doc/library
parent257d38ffdd5e85c17e14d63e1930e4756864878f (diff)
downloadcpython-62165d67a25229fee85c98cef9d1feaf109b1339.zip
cpython-62165d67a25229fee85c98cef9d1feaf109b1339.tar.gz
cpython-62165d67a25229fee85c98cef9d1feaf109b1339.tar.bz2
Document that the 'strict' error handler is used to encode/decode filenames on
Windows
Diffstat (limited to 'Doc/library')
-rw-r--r--Doc/library/os.rst8
1 files changed, 2 insertions, 6 deletions
diff --git a/Doc/library/os.rst b/Doc/library/os.rst
index b22c2e9..92bd606 100644
--- a/Doc/library/os.rst
+++ b/Doc/library/os.rst
@@ -158,9 +158,7 @@ process and user.
.. function:: fsencode(filename)
Encode *filename* to the filesystem encoding with ``'surrogateescape'``
- error handler, return :class:`bytes` unchanged. On Windows, use ``'strict'``
- error handler if the filesystem encoding is ``'mbcs'`` (which is the default
- encoding).
+ error handler, or ``'strict'`` on Windows; return :class:`bytes` unchanged.
:func:`fsdecode` is the reverse function.
@@ -170,9 +168,7 @@ process and user.
.. function:: fsdecode(filename)
Decode *filename* from the filesystem encoding with ``'surrogateescape'``
- error handler, return :class:`str` unchanged. On Windows, use ``'strict'``
- error handler if the filesystem encoding is ``'mbcs'`` (which is the default
- encoding).
+ error handler, or ``'strict'`` on Windows; return :class:`str` unchanged.
:func:`fsencode` is the reverse function.