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:
authorBastien Montagne <montagne29@wanadoo.fr>2018-05-11 11:49:58 +0300
committerBastien Montagne <montagne29@wanadoo.fr>2018-05-11 11:49:58 +0300
commitd19c8605f886681fa5260ac6611d28bee8fd3a33 (patch)
treed8ac53a3e4420eae9a158a33b59c872f68647a3d /source/blender/blenkernel/intern/icons.c
parentbcb245bd7137a8c3df061ed349c41c2247c6ef0f (diff)
parent13beeb58922747cc1a28bac58ceb1b44820808cd (diff)
Merge branch 'master' into blender2.8
Diffstat (limited to 'source/blender/blenkernel/intern/icons.c')
-rw-r--r--source/blender/blenkernel/intern/icons.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/source/blender/blenkernel/intern/icons.c b/source/blender/blenkernel/intern/icons.c
index e1d1211f6e5..f1f343faac8 100644
--- a/source/blender/blenkernel/intern/icons.c
+++ b/source/blender/blenkernel/intern/icons.c
@@ -564,8 +564,12 @@ static int icon_id_ensure_create_icon(struct ID *id)
int BKE_icon_id_ensure(struct ID *id)
{
- if (!id || G.background)
+ /* Never handle icons in non-main thread! */
+ BLI_assert(BLI_thread_is_main());
+
+ if (!id || G.background) {
return 0;
+ }
if (id->icon_id)
return id->icon_id;