diff options
author | Ton Roosendaal <ton@blender.org> | 2006-11-17 15:44:15 +0300 |
---|---|---|
committer | Ton Roosendaal <ton@blender.org> | 2006-11-17 15:44:15 +0300 |
commit | 6b9bf57066a0ee24902a13f5a371eb711bb7b86a (patch) | |
tree | 30c80347477e8ab7500a0a10e9761b0232b57080 /source/blender/python/BPY_interface.c | |
parent | 414b918010e19516b1e9c05f7ef7339f116be6e4 (diff) |
Yuck, a very ancient crasher in going area-full screen in Blender.
I wonder how this survived so long in Blender... (2005/03/09 commit).
Reason was the call to BPY_free_screen_spacehandlers(sc) in kernel,
which was freeing up scripthandlers in a weird way. That call is
really obsolete. The real freeing should go in the del_area() call,
to prevent copying and deleting area in the UI to go wrong.
(Crash happened in testing timeline markers, and holding CTRL+Uparrow
a while...)
Diffstat (limited to 'source/blender/python/BPY_interface.c')
-rw-r--r-- | source/blender/python/BPY_interface.c | 18 |
1 files changed, 6 insertions, 12 deletions
diff --git a/source/blender/python/BPY_interface.c b/source/blender/python/BPY_interface.c index fcf00a895e2..755842a9754 100644 --- a/source/blender/python/BPY_interface.c +++ b/source/blender/python/BPY_interface.c @@ -116,8 +116,6 @@ PyObject *blender_import( PyObject * self, PyObject * args ); void BPY_Err_Handle( char *script_name ); PyObject *traceback_getFilename( PyObject * tb ); -void BPY_free_screen_spacehandlers(struct bScreen *sc); - /**************************************************************************** * Description: This function will start the interpreter and load all modules * as well as search for a python installation. @@ -1648,23 +1646,19 @@ int BPY_do_spacehandlers( ScrArea *sa, unsigned short event, void BPY_free_scriptlink( struct ScriptLink *slink ) { if( slink->totscript ) { - if( slink->flag ) + if( slink->flag ) { MEM_freeN( slink->flag ); - if( slink->scripts ) + slink->flag= NULL; + } + if( slink->scripts ) { MEM_freeN( slink->scripts ); + slink->scripts= NULL; + } } return; } -void BPY_free_screen_spacehandlers(struct bScreen *sc) -{ - ScrArea *sa; - - for (sa = sc->areabase.first; sa; sa = sa->next) - BPY_free_scriptlink(&sa->scriptlink); -} - static int CheckAllSpaceHandlers(Text *text) { bScreen *screen; |