mirror of
https://github.com/python/cpython.git
synced 2025-09-26 10:19:53 +00:00
Issue #28748: Private variable _Py_PackageContext is now of type "const char *"
rather of "char *".
This commit is contained in:
parent
1fb1c998b2
commit
b57d9eac41
5 changed files with 7 additions and 4 deletions
|
@ -188,7 +188,7 @@ PyModule_Create2(struct PyModuleDef* module, int module_api_version)
|
|||
(if the name actually matches).
|
||||
*/
|
||||
if (_Py_PackageContext != NULL) {
|
||||
char *p = strrchr(_Py_PackageContext, '.');
|
||||
const char *p = strrchr(_Py_PackageContext, '.');
|
||||
if (p != NULL && strcmp(module->m_name, p+1) == 0) {
|
||||
name = _Py_PackageContext;
|
||||
_Py_PackageContext = NULL;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue