diff options
author | Willian Padovani Germano <wpgermano@gmail.com> | 2006-05-02 06:42:08 +0400 |
---|---|---|
committer | Willian Padovani Germano <wpgermano@gmail.com> | 2006-05-02 06:42:08 +0400 |
commit | 35b8dac2ca3bf8b2cdd51c8a7a071321f26753ba (patch) | |
tree | 63ddde059b59ed8d4714630fc8d4b21ed154f577 /source/blender/blenkernel/intern/script.c | |
parent | 30f4f3e2c4175e716c2aeb929bcfb9486ded18ae (diff) |
As mentioned in the pydrivers commit, I had to change the order in
exit_usiblender() to finalize Python before main library data was freed.
This solved a somewhat specific sigsegv with pydrivers, but as Ken
Hughes found out (thanks!) caused one with scripts that called Blender.Exit().
Now running scripts (G.main->script) are freed in BPY_end_python()
itself (so before the rest of the library data is freed), before
Py_Finalize(). Works fine in all my tests so far.
The file script.c should become obsolete with this change (I added a
comment about it there). If all is indeed fine, it will be removed
later.
Diffstat (limited to 'source/blender/blenkernel/intern/script.c')
-rw-r--r-- | source/blender/blenkernel/intern/script.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/source/blender/blenkernel/intern/script.c b/source/blender/blenkernel/intern/script.c index 16b08e37b6c..b99c2c51441 100644 --- a/source/blender/blenkernel/intern/script.c +++ b/source/blender/blenkernel/intern/script.c @@ -54,6 +54,9 @@ #endif */ +/* XXX this function and so also the file should not be needed anymore, + * since we have to force clearing all Python related data before freeing + * Blender's library. Still testing, will decide later (Willian). */ void free_script (Script *script) { if (!script) return; |