mirror of
https://github.com/python/cpython.git
synced 2025-07-28 13:44:43 +00:00
PyImport_AppendInittab() took a char * as a first argument even though that
string was stored beyond the life of the call. Changed the signature to be const char * to help make this point. Closes issue #1419652.
This commit is contained in:
parent
c730a6a123
commit
c4f90ebea7
3 changed files with 5 additions and 2 deletions
|
@ -3376,7 +3376,7 @@ PyImport_ExtendInittab(struct _inittab *newtab)
|
|||
/* Shorthand to add a single entry given a name and a function */
|
||||
|
||||
int
|
||||
PyImport_AppendInittab(char *name, void (*initfunc)(void))
|
||||
PyImport_AppendInittab(const char *name, void (*initfunc)(void))
|
||||
{
|
||||
struct _inittab newtab[2];
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue