From 664201170631e3029c99251a1d89ded5b2fed93b Mon Sep 17 00:00:00 2001 From: David Marcec Date: Fri, 13 Jul 2018 10:35:44 +1000 Subject: [PATCH 1/2] initialized voice status and unused sizes in the update data header --- src/core/hle/service/audio/audren_u.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/core/hle/service/audio/audren_u.cpp b/src/core/hle/service/audio/audren_u.cpp index 2da936b27..59d92f9ee 100644 --- a/src/core/hle/service/audio/audren_u.cpp +++ b/src/core/hle/service/audio/audren_u.cpp @@ -47,7 +47,7 @@ public: // Start the audio event CoreTiming::ScheduleEvent(audio_ticks, audio_event); - voice_status_list.reserve(worker_params.voice_count); + voice_status_list.resize(worker_params.voice_count); } ~IAudioRenderer() { CoreTiming::UnscheduleEvent(audio_event, 0); @@ -183,7 +183,9 @@ private: behavior_size = 0xb0; memory_pools_size = (config.effect_count + (config.voice_count * 4)) * 0x10; voices_size = config.voice_count * 0x10; + voice_resource_size = 0x0; effects_size = config.effect_count * 0x10; + mixes_size = 0x0; sinks_size = config.sink_count * 0x20; performance_manager_size = 0x10; total_size = sizeof(UpdateDataHeader) + behavior_size + memory_pools_size + From 8bd8d1e3da8ed87385589255902557c43f58275f Mon Sep 17 00:00:00 2001 From: David Marcec Date: Fri, 13 Jul 2018 10:36:28 +1000 Subject: [PATCH 2/2] We only need to alert for memory pool changes --- src/core/hle/service/audio/audren_u.cpp | 2 -- 1 file changed, 2 deletions(-) diff --git a/src/core/hle/service/audio/audren_u.cpp b/src/core/hle/service/audio/audren_u.cpp index 59d92f9ee..b7f591c6d 100644 --- a/src/core/hle/service/audio/audren_u.cpp +++ b/src/core/hle/service/audio/audren_u.cpp @@ -87,8 +87,6 @@ private: memory_pool[i].state = MemoryPoolStates::Attached; else if (mem_pool_info[i].pool_state == MemoryPoolStates::RequestDetach) memory_pool[i].state = MemoryPoolStates::Detached; - else - memory_pool[i].state = mem_pool_info[i].pool_state; } std::memcpy(output.data() + sizeof(UpdateDataHeader), memory_pool.data(), response_data.memory_pools_size);