comparison src/if_python3.c @ 19846:4acb165ed0bc v8.2.0479

patch 8.2.0479: unloading shared libraries on exit has no purpose Commit: https://github.com/vim/vim/commit/2027973b5be693577bea0731b50ea4904d19ea8b Author: Bram Moolenaar <Bram@vim.org> Date: Sun Mar 29 20:51:07 2020 +0200 patch 8.2.0479: unloading shared libraries on exit has no purpose Problem: Unloading shared libraries on exit has no purpose. Solution: Do not unload shared libraries on exit.
author Bram Moolenaar <Bram@vim.org>
date Sun, 29 Mar 2020 21:00:03 +0200
parents 1de842e3c329
children 10eb6c38938c
comparison
equal deleted inserted replaced
19845:32787925de3c 19846:4acb165ed0bc
633 # undef Py_XDECREF 633 # undef Py_XDECREF
634 # define Py_XDECREF(op) py3__Py_XDECREF(_PyObject_CAST(op)) 634 # define Py_XDECREF(op) py3__Py_XDECREF(_PyObject_CAST(op))
635 # endif 635 # endif
636 636
637 /* 637 /*
638 * Free python.dll
639 */
640 static void
641 end_dynamic_python3(void)
642 {
643 if (hinstPy3 != 0)
644 {
645 close_dll(hinstPy3);
646 hinstPy3 = 0;
647 }
648 }
649
650 /*
651 * Load library and get all pointers. 638 * Load library and get all pointers.
652 * Parameter 'libname' provides name of DLL. 639 * Parameter 'libname' provides name of DLL.
653 * Return OK or FAIL. 640 * Return OK or FAIL.
654 */ 641 */
655 static int 642 static int
871 PyGILState_Ensure(); 858 PyGILState_Ensure();
872 859
873 Py_Finalize(); 860 Py_Finalize();
874 } 861 }
875 862
876 #ifdef DYNAMIC_PYTHON3
877 end_dynamic_python3();
878 #endif
879
880 --recurse; 863 --recurse;
881 } 864 }
882 865
883 #if (defined(DYNAMIC_PYTHON3) && defined(DYNAMIC_PYTHON) && defined(FEAT_PYTHON) && defined(UNIX)) || defined(PROTO) 866 #if (defined(DYNAMIC_PYTHON3) && defined(DYNAMIC_PYTHON) && defined(FEAT_PYTHON) && defined(UNIX)) || defined(PROTO)
884 int 867 int