This attempts to work around CT#1650, which causes A/C/Es to be unlinked after creation of a sub-app and aso causes the global SDK object to be deleted upon destruction of any sub-app, which causes a crash the next time the global SDK pointer has to be dereferenced.
The workaround uses a static local variable to construct the global SDK object the first time and then assign its address to the global SDK pointer. It seems to work as expected, but might cause unexpected results if Fusion does not unload and reload the extension MFX after calling Free and before calling Initialize, though I have never been able to find a case where this happens (and I am very doubtful that this may happen in the future).
This attempts to work around CT#1650, which causes A/C/Es to be unlinked after creation of a sub-app and aso causes the global SDK object to be deleted upon destruction of any sub-app, which causes a crash the next time the global SDK pointer has to be dereferenced.
The workaround uses a static local variable to construct the global SDK object the first time and then assign its address to the global SDK pointer. It seems to work as expected, but might cause unexpected results if Fusion does not unload and reload the extension MFX after calling Free and before calling Initialize, though I have never been able to find a case where this happens (and I am very doubtful that this may happen in the future).