Hello!
I can confirm your symptoms. I also have an explanation and a solution.
First let me explain what goes wrong. This is a subtle thing, not very obvious at all.
THE ISSUE
In VSOS we have two standard audio file handles: stdaudioin and stdaudioout. In your configuration they
are by default not defined, i.e. they are NULL pointers:
NULL -> (NOTHING) -> NULL
When you load auxi2sm.dl3, you populate both stdaudioin and stdaudioout. So, now you have two file handles, but nothing yet in between:
stdaudioin(auxi2sm) -> (NOTHING) -> stdaudiout(auxi2sm)
Now you load AUXPLAY. AuxPlay reads data from stdaudioin and writes it to stdaudioout. So now we have the following audio chain:
stdaudioin(auxi2sm) -> AUXPLAY -> stdaudiout(auxi2sm)
Now you load FtOEqu. FtOEqu connects to the original driver that is there in stdaudioout, replaces it with itself, and then starts running all data sent to stdaudioout through itself:
stdaudioin(auxi2sm) -> AUXPLAY -> stdaudiout(ftoequ) -> (auxi2sm)
Now, when you unload FtOEqu from memory, if reverses its operation by removing itself from the audio path, and restoring stdaudioout to point to the original driver, then FtOEqu is removed from memory. So the audio path will again look like this:
stdaudioin(auxi2sm) -> AUXPLAY -> stdaudiout(auxi2sm)
However, and here comes the problem: when FtOEqu removes itself from the audio path and memory, a call by AUXPLAY to FtOEqu may still be going on. So we are essentially calling a library that has been removed from memory, and you end up with exactly the kind of crash you have seen.
SOLUTION #1
This is kind of an easy way out: don't remove FtOEqu from memory.
If this is not an option, there is the following alternative:
SOLUTION #2
Always remove AUXPLAY from memory before FtOEqu. That way AUXPLAY cannot call FtOEqu while FtOEqu is being removed from the audio path. For instance, like this:
Code: Select all
S:>driver -AUXPLAY
S:>driver -FTOEQU
The first command will restore the audio path to:
stdaudioin(auxi2sm) -> (NOTHING) -> stdaudiout(ftoequ) -> (auxi2sm)
... and the second one to ...
stdaudioin(auxi2sm) -> (NOTHING) -> stdaudiout(auxi2sm)
So this way the drivers unload peacefully. Then you can, if needed, reload one or both of the drivers.
Hope this helps!
Kind regards,
- Henrik
Good signatures never die. They just fade away.