Thanks for confirming thats not it.
The code is pretty big, crashes happen on random, on different machines (not on my dev machine unfortunately, also not on virtual machines), hard to debug. Heaptrc tells something is freed TWICE (was released at -> freed again at), unfortunately I cant see which line is that, stack trace is just addresses. Optimizations on or off makes no difference.
In other apps stack trace contains some info about where it is, but not in this particular app. Just addresses, not much.
But yes, I can force it to crash by forcing it to do much work, so I keep digging.