mirror of
https://github.com/python/cpython.git
synced 2025-08-04 00:48:58 +00:00
bpo-36362: Avoid unused variables when HAVE_DYNAMIC_LOADING is not defined (GH-12430)
https://bugs.python.org/issue36362
This commit is contained in:
parent
c70ab02df2
commit
0d765e3849
1 changed files with 3 additions and 2 deletions
|
@ -1983,13 +1983,14 @@ _imp_extension_suffixes_impl(PyObject *module)
|
||||||
/*[clinic end generated code: output=0bf346e25a8f0cd3 input=ecdeeecfcb6f839e]*/
|
/*[clinic end generated code: output=0bf346e25a8f0cd3 input=ecdeeecfcb6f839e]*/
|
||||||
{
|
{
|
||||||
PyObject *list;
|
PyObject *list;
|
||||||
const char *suffix;
|
|
||||||
unsigned int index = 0;
|
|
||||||
|
|
||||||
list = PyList_New(0);
|
list = PyList_New(0);
|
||||||
if (list == NULL)
|
if (list == NULL)
|
||||||
return NULL;
|
return NULL;
|
||||||
#ifdef HAVE_DYNAMIC_LOADING
|
#ifdef HAVE_DYNAMIC_LOADING
|
||||||
|
const char *suffix;
|
||||||
|
unsigned int index = 0;
|
||||||
|
|
||||||
while ((suffix = _PyImport_DynLoadFiletab[index])) {
|
while ((suffix = _PyImport_DynLoadFiletab[index])) {
|
||||||
PyObject *item = PyUnicode_FromString(suffix);
|
PyObject *item = PyUnicode_FromString(suffix);
|
||||||
if (item == NULL) {
|
if (item == NULL) {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue