mirror of
https://github.com/godotengine/godot
synced 2024-11-02 14:03:02 +00:00
Fix crash when previewing null AudioStream
This commit is contained in:
parent
3573d5f4ae
commit
a327a0078b
1 changed files with 2 additions and 1 deletions
|
@ -169,6 +169,7 @@ Ref<AudioStreamPreview> AudioStreamPreviewGenerator::generate_preview(const Ref<
|
|||
preview->preview->preview = maxmin;
|
||||
preview->preview->length = len_s;
|
||||
|
||||
if (preview->playback.is_valid())
|
||||
preview->thread = Thread::create(_preview_thread, preview);
|
||||
|
||||
return preview->preview;
|
||||
|
|
Loading…
Reference in a new issue