rlottie icon indicating copy to clipboard operation
rlottie copied to clipboard

On Windows rlottie hangs (forever) on application shutdown when compiled with MinGW

Open leonstyhre opened this issue 3 years ago • 1 comments

Hi!

If rlottie is compiled using MinGW 9.2.0 then the application will hang (seemingly forever) on shutdown if either render() or renderSync() has been called at least one.

This problem does not occur when compiled using MSVC but unfortunately I need to use MinGW for my release builds so that's not a solution for me.

I have also not seen the issue on any of the other operating systems that I've built rlottie on (macOS, Linux, FreeBSD, NetBSD and OpenBSD).

This issue is present on the master branch with the latest commit 875626965959d8e269ca22175c8e1ad190696c43. I have compiled as shared library/DLL and apart from the hang on shutdown, everything seems to work fine with correct rendering and equivalent performance compared to other platforms.

Many thanks in advance!

leonstyhre avatar Jan 07 '22 20:01 leonstyhre

One additional comment, I just managed to get the MinGW build to work by disabling the threading support using the LOTTIE_THREAD option. After doing this the application shuts down correctly.

So the issue is definitely related to threading somehow.

leonstyhre avatar Jan 07 '22 20:01 leonstyhre