On Dec 4, 2007, at 9:56 PM, Benny Prijono wrote: > Norman Franke wrote: >> I've been experiencing a large number of crashes in PJSIP of late >> (using >> the latest SVN head.) I never seemed to have these issues with >> 0.6. All >> crashes seem all revolve around using the pools. The latest is here: > > What if you > #define PJ_SAFE_POOL 1 > in your config_site.h? > > This will not make the crash go away, but it will assert when the > pool is destroyed more than once (btw I assume you enabled assertion > in your build). I did re-enable asserts, which is how I found #1 below. I think I traced it to several issues: 1. When calls end, the conference port is not automatically released. Why not? After a while, 32 active connects were established and things failed. After adding explicit pjsua_conf_disconnect (for each other connected port to that call) that assert stopped aborting. 2. I have a recorder that I use to record calls. I had originally used a single pool for this, and then destroyed and recreated the recorder as needed. Apparently, the memory was never freed by pjmedia_port_destroy and the pool kept growing. After some point, it would just crash (after the pool reached 1/2 to 3/4 of a MB.) The new version releases the whole pool and creates a new one when I call pjmedia_my_writer_port_create. With these two changes, I haven't had a crash in a day. However, I'm still puzzled why it crashed? I never used the pools in another thread, just to create the ports. I did try PJ_SAFE_POOL earlier and besides slowing the audio down to where it was garbled, I never got an error after a large number of test calls. -Norman -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.pjsip.org/pipermail/pjsip_lists.pjsip.org/attachments/20071205/f00c8023/attachment.html