Search Unity

"Run-Time Check Failure #0-The value of ESP was not properly saved across a function call" in Plugin

Discussion in 'VR' started by jahuu, Jul 26, 2017.

  1. jahuu

    jahuu

    Joined:
    Jun 2, 2017
    Posts:
    9
    I'm getting this error when using the native audio plugin demo from the Unity Repo, when I build it for Windows Store. I'm trying to use a custom audio spatializer for my HoloLens/WinMixedReality App.


    I can only work around it when disabling the debugger message for this exception (then the app starts "normal"), but this is obviously not a solution outside of the debugging environment.

    There have been serveral other posts about this (suggesting a missing __stdcall for the called function or so), but they don't really help me since Unity Engine calls those functions(and what functions anyway)? I might still be missing something here, or is this a bug in the audio plugin API?

    I'd appreciate any help with this. Thank you!

    Here is some callstack information. My Unity Version is Version 2017.2.0b2
     
  2. unity_andrewc

    unity_andrewc

    Unity Technologies

    Joined:
    Dec 14, 2015
    Posts:
    223
    An audio dev here says this looks like something we might need to fix on our end. Would you mind filing a bug report for us?
     
  3. jahuu

    jahuu

    Joined:
    Jun 2, 2017
    Posts:
    9
  4. unity_andrewc

    unity_andrewc

    Unity Technologies

    Joined:
    Dec 14, 2015
    Posts:
    223
  5. jahuu

    jahuu

    Joined:
    Jun 2, 2017
    Posts:
    9
    So the bug report team claims:
    I can reproduce this, the app starts up nicely and without breaking into any exceptions, however a few further tests showed that the native audio plugin is not even called in Master build. (E.g. i tried not returning output data from the plugin or switching the channels from left to right. Debug build had the changed audio behaviour, while Master build didn't.)

    I'm not super experienced with the build procedure of unity and UWP, but do I have to rebuild the plugin for Release so it can be called in the Master build? Or is this more of another bug and should work with the same DLL anyway? (kind of how it does in Release build of the app, only that i cannot step over the exception.) Do you guys have any idea what to make of this? :)