Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
bpo-45375: Fix off by one error in buffer allocation
  • Loading branch information
zooba committed Oct 6, 2021
commit 98902abbf6e73734ded5bcccf2866ba8abfc0aa4
2 changes: 1 addition & 1 deletion PC/getpathp.c
Original file line number Diff line number Diff line change
Expand Up @@ -266,7 +266,7 @@ canonicalize(wchar_t *buffer, const wchar_t *path)
}

if (PathIsRelativeW(path)) {
wchar_t buff[MAXPATHLEN];
wchar_t buff[MAXPATHLEN + 1];
if (!GetCurrentDirectoryW(MAXPATHLEN, buff)) {
return _PyStatus_ERR("unable to find current working directory");
}
Expand Down