Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSergey Sharybin <sergey.vfx@gmail.com>2014-12-11 14:55:10 +0300
committerSergey Sharybin <sergey.vfx@gmail.com>2014-12-11 14:55:10 +0300
commitcb7cf523e5c000609f32a382e2c0fcc57f635a42 (patch)
treeedb6bbd856dd268119c0229691b2b1792736a87c
parent1999b5a8147129ac7b82a5e57420ab8e5d7734a2 (diff)
Fix T42829: Cycles crash rendering when file is saved to specific location
The issue was caused by the way how RNA pointer was created for the bMain: namely Cycles was using RNA_id_pointer_create to create the pointer, which would then try to refine the poniter based on the ID type. This is just wrong and worked so far just because of co-incident, with the file path from the bug report first letters in the ID name happened to be NT which corresponds to NodeTree, and for sure refining such pointer will fail. Simple solution -- use proper way to create RNA pointer for non-ID block.
-rw-r--r--intern/cycles/blender/blender_python.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/intern/cycles/blender/blender_python.cpp b/intern/cycles/blender/blender_python.cpp
index dd45ae0865c..c48ec00ac6e 100644
--- a/intern/cycles/blender/blender_python.cpp
+++ b/intern/cycles/blender/blender_python.cpp
@@ -105,7 +105,7 @@ static PyObject *create_func(PyObject *self, PyObject *args)
BL::UserPreferences userpref(userprefptr);
PointerRNA dataptr;
- RNA_id_pointer_create((ID*)PyLong_AsVoidPtr(pydata), &dataptr);
+ RNA_main_pointer_create((Main*)PyLong_AsVoidPtr(pydata), &dataptr);
BL::BlendData data(dataptr);
PointerRNA sceneptr;