Menu

#12 libdispatch does not free all resources when dlclose() is called

1.0
open
nobody
None
2014-01-04
2014-01-04
Mark Heily
No

libdispatch does not free all resources when dlclose() is called. This causes a segfault if you call dlopen() again, because it tries to reinitialize pthread keys.

See the attached patch for a solution. I think we should consider using attribute((destructor)) and attribute((constructor)) to eliminate the need for the user to call libdispatch_init() or libdispatch_deinit().

1 Attachments

Discussion

  • Mark Heily

    Mark Heily - 2014-01-04
     
  • Mark Heily

    Mark Heily - 2014-01-04

    patch attached, based on a mailing list post

     

Log in to post a comment.