summaryrefslogtreecommitdiff
path: root/platform/javascript
diff options
context:
space:
mode:
authorRĂ©mi Verschelde <rverschelde@gmail.com>2017-09-17 22:48:22 +0200
committerGitHub <noreply@github.com>2017-09-17 22:48:22 +0200
commit53bbc046ee670a1c24b1ec936066857ef6e73dc9 (patch)
tree912835b1b1872785c0ffadda66d8996f5e7f9823 /platform/javascript
parenta00f19a92109ec33de41308e6277b55eb444320d (diff)
parent7a4c0ff35e10fba5f2686e7fd5623eab31b07a2d (diff)
Merge pull request #11252 from marcelofg55/fix_noaudio_crash
Fix crash when no audio driver is available
Diffstat (limited to 'platform/javascript')
-rw-r--r--platform/javascript/os_javascript.cpp6
1 files changed, 1 insertions, 5 deletions
diff --git a/platform/javascript/os_javascript.cpp b/platform/javascript/os_javascript.cpp
index 543d028576..67d2a6e369 100644
--- a/platform/javascript/os_javascript.cpp
+++ b/platform/javascript/os_javascript.cpp
@@ -464,11 +464,7 @@ void OS_JavaScript::initialize(const VideoMode &p_desired, int p_video_driver, i
print_line("Init Audio");
AudioDriverManager::add_driver(&audio_driver_javascript);
- audio_driver_javascript.set_singleton();
- if (audio_driver_javascript.init() != OK) {
-
- ERR_PRINT("Initializing audio failed.");
- }
+ AudioDriverManager::initialize(p_audio_driver);
RasterizerGLES3::register_config();
RasterizerGLES3::make_current();