[Date Prev][Date Next]
Re: (ITS#6993) Backend Connection problem
> Full_Name: Yann Carre
> Version: 2.4.26
> OS: red hat 5 (64 bits)
> URL: ftp://ftp.openldap.org/incoming/
> Submission from: (NULL) (18.104.22.168)
> I work on a specific Backend
> I have provided in my back end a function to the bi_connection_init
> This function adds a context needed in the operation backend function
> When several connections start up, my LDAP server crashes.
> The crash arrives because the context is not created before the call to
> The connection is provided to the application Backend before my Back end
> I have checked it with the debugger and see that the thread with
> initialize the
> connection is suspend before the backend connection_init. In another
> thread, the
> search function is executed without any context attached to the
> This problem seems to be bring because the connection mutex is freed
> before the
> calling of the Back end connection_init in the function connection_init
> I have moved this mutex after the backend connection_init and it seems to
> Would you confirm this analysis and take the correction in account?
Honestly, if that context you mention is connection-specific, I don't see
how this could happen, since operations on that connection should not be
possible until connection_init() returns.
OTOH, if the context is global, you should initialize it differently, and
protect it from being used before its initialization is complete, e.g. by
a specific mutex that is completely internal to your backend.
In any case, it is not clear how this can be an OpenLDAP bug. You should
provide a clearer evidence. In the absence, I'd consider this ITS closed.