diff options
author | Campbell Barton <ideasman42@gmail.com> | 2010-12-08 06:25:31 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2010-12-08 06:25:31 +0300 |
commit | 23a49334ed3a8d1749728c358c8b1e2aed3c6473 (patch) | |
tree | 0a0d4beecec5d1efb3944dd26222200817a9be9c /source/blender/python | |
parent | 2e667e45fc02c5de285df836e59248a82b45dff9 (diff) |
fix for own change r33524, at the moment the context always has to be valid, noted with XXX.
reported by Doug Hammond.
Diffstat (limited to 'source/blender/python')
-rw-r--r-- | source/blender/python/intern/bpy_rna.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/source/blender/python/intern/bpy_rna.c b/source/blender/python/intern/bpy_rna.c index ee393c5fe15..e4c54f86ea9 100644 --- a/source/blender/python/intern/bpy_rna.c +++ b/source/blender/python/intern/bpy_rna.c @@ -5154,6 +5154,11 @@ static int bpy_class_call(bContext *C, PointerRNA *ptr, FunctionRNA *func, Param return -1; } + /* XXX, this is needed because render engine calls without a context + * this should be supported at some point but at the moment its not! */ + if(C==NULL) + C= BPy_GetContext(); + bpy_context_set(C, &gilstate); if (!is_static) { |