- Crashes on unhandled read violation at nullptr (0x0000000000000000)
- Unreal 4.22
- Wwise 2019.1.1.6977
- Engine Plugin
- Vanilla Third Party DLL's (straight from the download, but we have the source for debugging)
- Occurs unpredictably at runtime while the game is posting events (reliably within 5 minutes of play)
Here's the callstack, I'm fairly certain this is a threading error in the AK engine:
[Inline Frame] [Redacted].exe!AKPLATFORM::AkMemCpy(void *) Line 351 C++
[Redacted].exe!Bypass_Native_NChan(AkAudioBuffer * io_pInBuffer, AkAudioBuffer * io_pOutBuffer, unsigned long uRequestedSize, AkInternalPitchState * io_pPitchState) Line 63 C++
[Redacted].exe!CAkResampler::Execute(AkAudioBuffer * io_pInBuffer, AkAudioBuffer * io_pOutBuffer) Line 372 C++
[Redacted].exe!CAkVPLPitchNode::ConsumeBuffer(AkVPLState & io_state) Line 176 C++
[Redacted].exe!CAkLEngine::RunVPL(CAkVPLSrcCbxNode * in_pCbx, AkVPLState & io_state) Line 2244 C++
[Inline Frame] [Redacted].exe!CAkLEngine::ProcessSources(bool) Line 2554 C++
[Redacted].exe!CAkLEngine::SoftwarePerform() Line 2325 C++
[Redacted].exe!CAkLEngine::Perform() Line 805 C++
[Redacted].exe!CAkAudioMgr::Perform() Line 562 C++
[Redacted].exe!CAkAudioThread::EventMgrThreadFunc(void * lpParameter) Line 74 C++
From what I can discern, the AkMemCpy is copying from a nullptr in the pitch resampler. The buffer which is attempting to be read passes an assert in ConsumeBuffer() that verifies it has a valid pointer, but when the Bypass_Native_NChan() call comes through later the buffer has become nullptr. We have the source code for making some necessary integration changes to the sound engine, but this crash comes from the vanilla third party .dll's which we're testing before re-making our internal changes as we upgrade Unreal and Wwise. Our changes worked fine on UE 4.20 with 2018.1.0.6714 but we need to upgrade to UE 4.22 and our audio team needs features in Wwise 2019.
I'm going to be tweaking the source and rebuilding this to attempt to keep this from crashing, but any help or knowledge on this issue would be greatly appreciated.
Let me know if there's any information that I can provide that I missed here.