diff options
author | Campbell Barton <ideasman42@gmail.com> | 2010-05-18 21:19:02 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2010-05-18 21:19:02 +0400 |
commit | 8ca3de6d630b908a129c9c04fe5d386f14b94957 (patch) | |
tree | 56ca8f185eeee0647a8498cc8d56bde94478cf00 /source | |
parent | 9bf6ce59602d965765811eb20eec2e9bbb405f3f (diff) |
fix for opengl render when called from python
Diffstat (limited to 'source')
-rw-r--r-- | source/blender/editors/space_view3d/view3d_view.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/source/blender/editors/space_view3d/view3d_view.c b/source/blender/editors/space_view3d/view3d_view.c index 6a661f18959..31ddc442cc2 100644 --- a/source/blender/editors/space_view3d/view3d_view.c +++ b/source/blender/editors/space_view3d/view3d_view.c @@ -1719,7 +1719,8 @@ int ED_view3d_context_activate(bContext *C) ARegion *ar; RegionView3D *rv3d; - if(sa->spacetype != SPACE_VIEW3D) + /* sa can be NULL when called from python */ + if(sa==NULL || sa->spacetype != SPACE_VIEW3D) for(sa=sc->areabase.first; sa; sa= sa->next) if(sa->spacetype==SPACE_VIEW3D) break; |