Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 44b4b6a

Browse files
committed
Fix compilation under Windows
1 parent 461c813 commit 44b4b6a

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

Python/import.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -426,12 +426,13 @@ PyImport_Cleanup(void)
426426
long
427427
PyImport_GetMagicNumber(void)
428428
{
429+
long res;
429430
PyInterpreterState *interp = PyThreadState_Get()->interp;
430431
PyObject *pyc_magic = PyObject_GetAttrString(interp->importlib,
431432
"_RAW_MAGIC_NUMBER");
432433
if (pyc_magic == NULL)
433434
return -1;
434-
long res = PyLong_AsLong(pyc_magic);
435+
res = PyLong_AsLong(pyc_magic);
435436
Py_DECREF(pyc_magic);
436437
return res;
437438
}

0 commit comments

Comments
 (0)