[debug] event_callback_finalize_many_: 3 events finalizing
[debug] event_del: 0x7fd99ad00b00 (fd -1), callback 0x1081175c0
[debug] event_del: 0x7fd99ad00b80 (fd -1), callback 0x108117620
[debug] event_del: 0x7fd99ad00b00 (fd -1), callback 0x1081175c0
[debug] event_del: 0x7fd99ac1e490 (fd 6), callback 0x10811b8f0
[debug] event_del: 0x7fd99ad00b00 (fd -1), callback 0x108116c70
[debug] event_callback_finalize_many_: 3 events finalizing
[debug] event_del: 0x7fd99ac1e490 (fd 6), callback 0x10811b8f0
[debug] event_del: 0x7fd99ac1e510 (fd 6), callback 0x10811bb30
[debug] event_del: 0x7fd99ac1e490 (fd 6), callback 0x10811b8f0
[debug] event_base_free_: 1 events were still set in base
[err] event.c:840: Assertion TAILQ_EMPTY(&base->activequeues[i]) failed in event_base_free_Abort trap: 6
I attached a small test program demonstrating the problem. You will have to change the LIBEVENT_BASE_DIR variable in the included Makefile.
I am able to get around the problem by not freeing the underlying bufferevent or by using event_base_free_nofinalize but then we are leaking memory according to valgrind.
It is not clear to me that I am even setting up this stuff properly even though it is working well. Any insight would be greatly appreciated!
Thanks for your time!
Topher
Attachment:
test_libevent_ssl_connect_disconnect.tar.gz
Description: GNU Zip compressed data