| To: vim_dev@googlegroups.com |
| Subject: Patch 7.3.691 |
| Fcc: outbox |
| From: Bram Moolenaar <Bram@moolenaar.net> |
| Mime-Version: 1.0 |
| Content-Type: text/plain; charset=UTF-8 |
| Content-Transfer-Encoding: 8bit |
| |
| |
| Patch 7.3.691 |
| Problem: State specific to the Python thread is discarded. |
| Solution: Keep state between threads. (Paul) |
| Files: src/if_python.c |
| |
| |
| |
| |
| |
| *** 740,748 **** |
| #else |
| PyMac_Initialize(); |
| #endif |
| ! /* initialise threads */ |
| PyEval_InitThreads(); |
| ! |
| #ifdef DYNAMIC_PYTHON |
| get_exceptions(); |
| #endif |
| --- 740,750 ---- |
| #else |
| PyMac_Initialize(); |
| #endif |
| ! /* Initialise threads and save the state using PyGILState_Ensure. |
| ! * Without this call, thread-specific state (such as the system trace |
| ! * hook), will be lost between invocations of Python code. */ |
| PyEval_InitThreads(); |
| ! pygilstate = PyGILState_Ensure(); |
| #ifdef DYNAMIC_PYTHON |
| get_exceptions(); |
| #endif |
| |
| |
| |
| *** 721,722 **** |
| --- 721,724 ---- |
| { /* Add new patch number below this line */ |
| + /**/ |
| + 691, |
| /**/ |
| |
| -- |
| ARTHUR: The swallow may fly south with the sun, or the house martin or the |
| plover seek warmer hot lands in winter, yet these are not strangers to |
| our land. |
| SOLDIER: Are you suggesting coconuts migrate? |
| "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD |
| |
| /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ |
| /// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ |
| \\\ an exciting new programming language -- http://www.Zimbu.org /// |
| \\\ help me help AIDS victims -- http://ICCF-Holland.org /// |