[Date Prev][Date Next] [Chronological] [Thread] [Top]

mutex leak - OpenLDAP 1.2.11



Hi,

I often perform the query on the cn=monitor object
to produce statistics (query is performed in my Unix crontab).

I have notice that when performing a query on cn=monitor,
"entry_rdwr_init(e);"  is called in "monitor.c"

This function call initialize 1 mutex (e.rw.ltrw_mutex)
and 2 conditions (e.rw.ltrw_read, e.rw.ltrw_write).

These mutex and conditions are never destroyed.

I'm not sure about the best correction :
- removing the "entry_rdwr_init(e);"  line
- calling "ldap_pvt_thread_rdwr_destroy( &(e->rw) )"
  before "entry_free(e)" in "monitor.c"
- updating the entry_free(e) function to destroy e.rw
  if initialized.

This bug is not critical since most systems do
not allocate ressources for mutexes.
Mutex ressources seem to be unlimited on the AIX
system I use.

But I don't really know if it's a problem,
because the "entry_rdwr_init" function
is also used in files add.c configinfo.c entry.c
without destroying the rdwr lock.


Thanks for any information or solution about this problem

    Elouen


===========================
Elouen LANOË
elouen.lanoe@ifrance.com
===========================

 
______________________________________________________________________________
message envoye depuis http://www.ifrance.com
emails (pop)-sites persos (espace illimite)-agenda-favoris (bookmarks)-forums 
Ecoutez ce message par tel ! : 08 92 68 92 15 (france uniquement)