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>2019-05-04 21:34:56 +0300
committerSergey Sharybin <sergey.vfx@gmail.com>2019-05-04 21:34:56 +0300
commitc68c81a870baa438a45e870aee677178632cce18 (patch)
tree5c06771ff5f932286abb236aa93e8455da7f9eac /source/blender/blenkernel/intern/sound.c
parentc02534469ac30746bb50f9106cdfc97196823537 (diff)
Sound: Make sure spin lock is initialized for new sound datablocks
Should have been done as a part of 9f681bea68f.
Diffstat (limited to 'source/blender/blenkernel/intern/sound.c')
-rw-r--r--source/blender/blenkernel/intern/sound.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/source/blender/blenkernel/intern/sound.c b/source/blender/blenkernel/intern/sound.c
index 7d335ab1347..d731c6e3eac 100644
--- a/source/blender/blenkernel/intern/sound.c
+++ b/source/blender/blenkernel/intern/sound.c
@@ -103,6 +103,9 @@ bSound *BKE_sound_new_file(Main *bmain, const char *filepath)
BLI_strncpy(sound->name, filepath, FILE_MAX);
/* sound->type = SOUND_TYPE_FILE; */ /* XXX unused currently */
+ sound->spinlock = MEM_mallocN(sizeof(SpinLock), "sound_spinlock");
+ BLI_spin_init(sound->spinlock);
+
BKE_sound_reset_runtime(sound);
return sound;