I tested it on my box and it seemed to be OK. So sorry for misunderstanding. Can you tell me, what was your libavastengine.so library version and your linux distro? I think, the bug occured when the shared library was unloaded.