summaryrefslogtreecommitdiff
path: root/Python/fileutils.c
diff options
context:
space:
mode:
authorVictor Stinner <vstinner@redhat.com>2019-03-19 02:58:14 +0100
committerGitHub <noreply@github.com>2019-03-19 02:58:14 +0100
commitfaddaedd05ca81a9fed3f315e7bc8dcf455824a2 (patch)
tree90679ab39bba190bd5cfa055ae3f564255d29495 /Python/fileutils.c
parent5f9cf23502febe0eb3bc02e45c7d2bfc79424757 (diff)
downloadcpython-git-faddaedd05ca81a9fed3f315e7bc8dcf455824a2.tar.gz
bpo-36352: Avoid hardcoded MAXPATHLEN size in getpath.c (GH-12423)
* Use Py_ARRAY_LENGTH() rather than hardcoded MAXPATHLEN in getpath.c. * Pass string length to functions modifying strings.
Diffstat (limited to 'Python/fileutils.c')
-rw-r--r--Python/fileutils.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/Python/fileutils.c b/Python/fileutils.c
index 0ac690a211..b933874193 100644
--- a/Python/fileutils.c
+++ b/Python/fileutils.c
@@ -1716,7 +1716,7 @@ _Py_wrealpath(const wchar_t *path,
}
#endif
-/* Get the current directory. size is the buffer size in wide characters
+/* Get the current directory. buflen is the buffer size in wide characters
including the null character. Decode the path from the locale encoding.
Return NULL on getcwd() error, on decoding error, or if 'buf' is