summaryrefslogtreecommitdiffstats
path: root/PC/_winreg.c
diff options
context:
space:
mode:
Diffstat (limited to 'PC/_winreg.c')
-rw-r--r--PC/_winreg.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/PC/_winreg.c b/PC/_winreg.c
index 34e4f68..965acf1 100644
--- a/PC/_winreg.c
+++ b/PC/_winreg.c
@@ -1459,6 +1459,8 @@ PyMODINIT_FUNC init_winreg(void)
{
PyObject *m, *d;
m = Py_InitModule3("_winreg", winreg_methods, module_doc);
+ if (m == NULL)
+ return;
d = PyModule_GetDict(m);
PyHKEY_Type.ob_type = &PyType_Type;
PyHKEY_Type.tp_doc = PyHKEY_doc;