Rocco Caputo wrote:

3) It's not quite there yet -- on exit, which calls Wx::wxTheApp->ExitMainLoop();
I get the following messages. Being relatively new to this level of POE internals, any suggestions of how to plug these leaks?


!!! Leaked session ID: 3 = POE::Session=ARRAY(0x8066448)


[... and a lot of other leak messages ...]

This looks like ExitMainLoop() is being called while sessions are
still active.  All the data structures are being cross checked for
improper shutdown, and they're coming up with positive hits.

Standard operating procedure is to keep the event loop running until
after the last user session has stopped.

I'll need to install WxPerl to run the test program and find out more.
Traditionally I haven't had much luck with WxPerl, though.


Figured it out -- instead of the app calling ExitMainLoop, it needs to call POE::Kernel->stop(), which will nicely call the loop_halt() in POE::Loop::Wx after cleaning up -- and loop_halt() calls ExitMainLoop -- no more leaks.




Reply via email to