Strange bug with frozen MainActivity on Android with release version of lime-legacy

Hello all!

I have a strange bug with Android target. This bug appears only with release lime-legacy.so, with debug lime-legacy everything works fine.

Bug: I’m using native extensions to open window of third-party library (for example Facebook SDK). When third-party window closed after, game is frozen for 5-10 minutes (!) Native extension itself receive callback onResume immediately after third-party window is closed.
It reproduces on the phone devices (Samsung Galaxy S3 and Xiaomi Redmi Note 3) and with release version of lime-legacy only, debug one is working fine. I know, that this problem can be caused by anything, but what the difference between debug and release versions of lime-legacy? Is it possible to use debug version of lime-legacy in release build?

Also, I’ve noticed that size of the release lime-legacy.so is 4.7mb, but size of the debug one is 18mb (huge difference!)

I’m using latest lime from repo (2.9)

Very strange! I’ve never heard of this before.

I’m not sure if native extensions behave differently for debug, but C++ in general includes additional stack and crash symbols and has a larger stack size, which can hide stack overflow crashes that occur only on release. Perhaps there are different compile flags between them that make a difference, but I’ve never heard of this issue :frowning: