diff options
author | Brecht Van Lommel <brechtvanlommel@pandora.be> | 2010-05-05 21:14:43 +0400 |
---|---|---|
committer | Brecht Van Lommel <brechtvanlommel@pandora.be> | 2010-05-05 21:14:43 +0400 |
commit | 0c495ffe10e77c6432960817967cd4ec32e930bf (patch) | |
tree | 6607bdc6c1c33f3295726ccc923b586241001006 /source/blender/gpu | |
parent | 12cf8ac1d6cfc640a4dae4377aa97609ee568f04 (diff) |
Fix for GPU_free_unused_buffers deadlock, solution by Tamito Kajiyama, thanks!
Diffstat (limited to 'source/blender/gpu')
-rw-r--r-- | source/blender/gpu/intern/gpu_draw.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/source/blender/gpu/intern/gpu_draw.c b/source/blender/gpu/intern/gpu_draw.c index 5c85abef581..6eb3e13c4e2 100644 --- a/source/blender/gpu/intern/gpu_draw.c +++ b/source/blender/gpu/intern/gpu_draw.c @@ -799,6 +799,9 @@ void GPU_free_unused_buffers(void) { Image *ima; + if(!BLI_thread_is_main()) + return; + BLI_lock_thread(LOCK_OPENGL); for(ima=image_free_queue.first; ima; ima=ima->id.next) |