bpo-38353: Fix typos in calculate_argv0_path_framework() (GH-16695)
bpo-38353, bpo-38429: Fix typos introduced by commit
c02b41b1fb
in
calculate_argv0_path_framework() of getpath.c.
This commit is contained in:
parent
d47f0dd2e8
commit
b6e0fc7426
|
@ -1126,7 +1126,7 @@ calculate_argv0_path_framework(PyCalculatePath *calculate, _PyPathConfig *pathco
|
||||||
}
|
}
|
||||||
|
|
||||||
reduce(parent);
|
reduce(parent);
|
||||||
wchar_t *lib_python = joinpath2(path, calculate->lib_python);
|
wchar_t *lib_python = joinpath2(parent, calculate->lib_python);
|
||||||
PyMem_RawFree(parent);
|
PyMem_RawFree(parent);
|
||||||
|
|
||||||
if (lib_python == NULL) {
|
if (lib_python == NULL) {
|
||||||
|
@ -1144,7 +1144,7 @@ calculate_argv0_path_framework(PyCalculatePath *calculate, _PyPathConfig *pathco
|
||||||
if (!module) {
|
if (!module) {
|
||||||
/* We are in the build directory so use the name of the
|
/* We are in the build directory so use the name of the
|
||||||
executable - we know that the absolute path is passed */
|
executable - we know that the absolute path is passed */
|
||||||
PyMem_RawFree(*calculate->argv0_path);
|
PyMem_RawFree(calculate->argv0_path);
|
||||||
calculate->argv0_path = _PyMem_RawWcsdup(pathconfig->program_full_path);
|
calculate->argv0_path = _PyMem_RawWcsdup(pathconfig->program_full_path);
|
||||||
if (calculate->argv0_path == NULL) {
|
if (calculate->argv0_path == NULL) {
|
||||||
status = _PyStatus_NO_MEMORY();
|
status = _PyStatus_NO_MEMORY();
|
||||||
|
@ -1156,8 +1156,8 @@ calculate_argv0_path_framework(PyCalculatePath *calculate, _PyPathConfig *pathco
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Use the location of the library as argv0_path */
|
/* Use the location of the library as argv0_path */
|
||||||
PyMem_RawFree(*calculate->argv0_path);
|
PyMem_RawFree(calculate->argv0_path);
|
||||||
calculate->argv0_path = wbuf
|
calculate->argv0_path = wbuf;
|
||||||
return _PyStatus_OK();
|
return _PyStatus_OK();
|
||||||
|
|
||||||
done:
|
done:
|
||||||
|
|
Loading…
Reference in New Issue