| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -5034,6 +5034,8 @@ DL_EXPORT(void) init_bsddb(void) | |||
| 5034 | 5034 | ||
| 5035 | 5035 | /* Create the module and add the functions */ | |
| 5036 | 5036 | m = Py_InitModule(_bsddbModuleName, bsddb_methods); | |
| 5037 | + if (m == NULL) | ||
| 5038 | + return; | ||
| 5037 | 5039 | ||
| 5038 | 5040 | /* Add some symbolic constants to the module */ | |
| 5039 | 5041 | d = PyModule_GetDict(m); | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -462,6 +462,8 @@ init_curses_panel(void) | |||
| 462 | 462 | ||
| 463 | 463 | /* Create the module and add the functions */ | |
| 464 | 464 | m = Py_InitModule("_curses_panel", PyCurses_methods); | |
| 465 | + if (m == NULL) | ||
| 466 | + return; | ||
| 465 | 467 | d = PyModule_GetDict(m); | |
| 466 | 468 | ||
| 467 | 469 | /* For exception _curses_panel.error */ | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -2481,6 +2481,8 @@ init_curses(void) | |||
| 2481 | 2481 | ||
| 2482 | 2482 | /* Create the module and add the functions */ | |
| 2483 | 2483 | m = Py_InitModule("_curses", PyCurses_methods); | |
| 2484 | + if (m == NULL) | ||
| 2485 | + return; | ||
| 2484 | 2486 | ||
| 2485 | 2487 | /* Add some symbolic constants to the module */ | |
| 2486 | 2488 | d = PyModule_GetDict(m); | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -2590,6 +2590,8 @@ init_elementtree(void) | |||
| 2590 | 2590 | #endif | |
| 2591 | 2591 | ||
| 2592 | 2592 | m = Py_InitModule("_elementtree", _functions); | |
| 2593 | + if (m == NULL) | ||
| 2594 | + return; | ||
| 2593 | 2595 | ||
| 2594 | 2596 | /* python glue code */ | |
| 2595 | 2597 | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -610,6 +610,8 @@ init_heapq(void) | |||
| 610 | 610 | PyObject *m; | |
| 611 | 611 | ||
| 612 | 612 | m = Py_InitModule3("_heapq", heapq_methods, module_doc); | |
| 613 | + if (m == NULL) | ||
| 614 | + return; | ||
| 613 | 615 | PyModule_AddObject(m, "__about__", PyString_FromString(__about__)); | |
| 614 | 616 | } | |
| 615 | 617 | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -715,6 +715,8 @@ init_locale(void) | |||
| 715 | 715 | #endif | |
| 716 | 716 | ||
| 717 | 717 | m = Py_InitModule("_locale", PyLocale_Methods); | |
| 718 | + if (m == NULL) | ||
| 719 | + return; | ||
| 718 | 720 | ||
| 719 | 721 | d = PyModule_GetDict(m); | |
| 720 | 722 | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -573,6 +573,8 @@ init_random(void) | |||
| 573 | 573 | if (PyType_Ready(&Random_Type) < 0) | |
| 574 | 574 | return; | |
| 575 | 575 | m = Py_InitModule3("_random", NULL, module_doc); | |
| 576 | + if (m == NULL) | ||
| 577 | + return; | ||
| 576 | 578 | Py_INCREF(&Random_Type); | |
| 577 | 579 | PyModule_AddObject(m, "Random", (PyObject *)&Random_Type); | |
| 578 | 580 | } | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -3389,6 +3389,8 @@ PyMODINIT_FUNC init_sre(void) | |||
| 3389 | 3389 | Scanner_Type.ob_type = &PyType_Type; | |
| 3390 | 3390 | ||
| 3391 | 3391 | m = Py_InitModule("_" SRE_MODULE, _functions); | |
| 3392 | + if (m == NULL) | ||
| 3393 | + return; | ||
| 3392 | 3394 | d = PyModule_GetDict(m); | |
| 3393 | 3395 | ||
| 3394 | 3396 | x = PyInt_FromLong(SRE_MAGIC); | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -634,6 +634,8 @@ init_ssl(void) | |||
| 634 | 634 | PySSL_Type.ob_type = &PyType_Type; | |
| 635 | 635 | ||
| 636 | 636 | m = Py_InitModule3("_ssl", PySSL_methods, module_doc); | |
| 637 | + if (m == NULL) | ||
| 638 | + return; | ||
| 637 | 639 | d = PyModule_GetDict(m); | |
| 638 | 640 | ||
| 639 | 641 | /* Load _socket module and its C API */ | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -627,6 +627,8 @@ init_testcapi(void) | |||
| 627 | 627 | PyObject *m; | |
| 628 | 628 | ||
| 629 | 629 | m = Py_InitModule("_testcapi", TestMethods); | |
| 630 | + if (m == NULL) | ||
| 631 | + return; | ||
| 630 | 632 | ||
| 631 | 633 | PyModule_AddObject(m, "UCHAR_MAX", PyInt_FromLong(UCHAR_MAX)); | |
| 632 | 634 | PyModule_AddObject(m, "USHRT_MAX", PyInt_FromLong(USHRT_MAX)); | |
| Back | FazBrowse Home | New Git URL |
0 commit comments