bpo-34725: Adds _Py_SetProgramFullPath so embedders may override sys.executable (GH-9860)

This commit is contained in:
Steve Dower 2018-11-17 20:41:48 -08:00 committed by GitHub
parent 689d555ec1
commit 177a41a07b
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
6 changed files with 74 additions and 33 deletions

View file

@ -982,6 +982,10 @@ done:
if (config->prefix == NULL) {
return _Py_INIT_NO_MEMORY();
}
config->exec_prefix = _PyMem_RawWcsdup(prefix);
if (config->exec_prefix == NULL) {
return _Py_INIT_NO_MEMORY();
}
return _Py_INIT_OK();
}