NAudio icon indicating copy to clipboard operation
NAudio copied to clipboard

System.MemoryAccessViolation Exception for WaveInEvent

Open SineVector241 opened this issue 4 months ago • 0 comments

This is an issue I only ran into once but I feel like it should be known. Basically when I stopped the WaveInEvent and disposed of it as my VOIP app timed out, it crashed with this error (I had to use Event Viewer to see the actual error). I believe this might be the case of no thread safety and no SafeHandle or reference count for the Interop. It's a very specific issue with a pretty specific timing to trigger even though I was stopping the WaveInEvent on the main thread.

Might be a one off issue but it could be an issue later down the track. image.png

SineVector241 avatar Apr 21 '24 02:04 SineVector241