ArthurSonzogni / smk

SMK - Simple multimedia kit - C++ WebAssembly
MIT License
125 stars 18 forks source link

[FIX] Conditional jumps and crash due to dtor call #16

Closed Guerout-Arnaud closed 2 years ago

Guerout-Arnaud commented 2 years ago

This PR fix an issue found in smk-starter repository and discussed here

To make it short, the destructor was called on this which indeed destruct the object itself which was then returned. This caused multiples conditional jumps and a crash.

Fixed by changing the call to the dtor to a call to the Release method.

File modified :

ArthurSonzogni commented 2 years ago

Thank you!