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

Skip to content

Commit c8a6e5b

Browse files
authored
sqlite: delete some bsddb cargo-culted code to work around Python 2.3/2.4 bugs
1 parent 058de11 commit c8a6e5b

1 file changed

Lines changed: 0 additions & 15 deletions

File tree

Modules/_sqlite/module.c

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -465,21 +465,6 @@ PyMODINIT_FUNC PyInit__sqlite3(void)
465465

466466
pysqlite_BaseTypeAdapted = 0;
467467

468-
/* Original comment from _bsddb.c in the Python core. This is also still
469-
* needed nowadays for Python 2.3/2.4.
470-
*
471-
* PyEval_InitThreads is called here due to a quirk in python 1.5
472-
* - 2.2.1 (at least) according to Russell Williamson <[email protected]>:
473-
* The global interpreter lock is not initialized until the first
474-
* thread is created using thread.start_new_thread() or fork() is
475-
* called. that would cause the ALLOW_THREADS here to segfault due
476-
* to a null pointer reference if no threads or child processes
477-
* have been created. This works around that and is a no-op if
478-
* threads have already been initialized.
479-
* (see pybsddb-users mailing list post on 2002-08-07)
480-
*/
481-
PyEval_InitThreads();
482-
483468
error:
484469
if (PyErr_Occurred())
485470
{

0 commit comments

Comments
 (0)