Windows: Close audiodriver sooner on exit

In #7839 I see the same error that was fixed in #7833 occuring on the
Windows platform. This moves the audio driver closing to the same place
in OS_Windows::finalize() as it is in OS_X11::finalize()

This fixes #7839
This commit is contained in:
Hein-Pieter van Braam 2017-02-19 20:42:36 +01:00
parent 5e3fc7d069
commit 04e51859f0
1 changed files with 5 additions and 6 deletions

View File

@ -1255,6 +1255,10 @@ void OS_Windows::finalize() {
main_loop=NULL; main_loop=NULL;
for (int i = 0; i < get_audio_driver_count(); i++) {
AudioDriverManager::get_driver(i)->finish();
}
memdelete(joypad); memdelete(joypad);
memdelete(input); memdelete(input);
@ -1282,13 +1286,8 @@ void OS_Windows::finalize() {
memdelete(physics_2d_server); memdelete(physics_2d_server);
monitor_info.clear(); monitor_info.clear();
for (int i = 0; i < get_audio_driver_count(); i++)
{
AudioDriverManager::get_driver(i)->finish();
}
} }
void OS_Windows::finalize_core() { void OS_Windows::finalize_core() {
memdelete(process_map); memdelete(process_map);